<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=us-ascii">
<META content="MSHTML 6.00.6000.16705" name=GENERATOR></HEAD>
<BODY>
<DIV dir=ltr align=left><FONT face=Arial><FONT color=#0000ff><FONT size=2><SPAN 
class=234111511-10122008>reply&nbsp;at bottom&nbsp;of mail 
...</SPAN></FONT></FONT></FONT><BR></DIV>
<DIV></DIV>
<DIV>&gt; poos001@D0400736:~/admb$ export 
ADMB_HOME=/home/poos001/admb-9.0.65-linux64-gcc3.4.6/<BR><BR>remove the trailing 
backslash, so that<BR>$ export 
ADMB_HOME=/home/poos001/admb-9.0.65-linux64-gcc3.4.6<BR><BR>then <BR>$ export 
PATH=$ADMB_HOME/bin:$PATH<BR><BR>finally<BR>$ tpl2rem envpref<BR><BR>let me 
know,<BR>johnoel<BR>----- Original Message -----<BR>From: "Poos, Jan Jaap" 
&lt;janjaap.Poos@wur.nl&gt;<BR>Date: Tuesday, December 9, 2008 10:49 
pm<BR>Subject: Re: [ADMB Users] glitch in tpl2rem (and tpl2cpp) ?<BR>To: 
users@admb-project.org<BR><BR>&gt; &nbsp;<BR>&gt; My reply is at 
bottom...<BR>&gt; <BR>&gt; -----Original Message-----<BR>&gt; From: 
users-bounces@admb-project.org [mailto:users-bounces@admb-<BR>&gt; project.org] 
On Behalf Of John Ancheta<BR>&gt; Sent: Tuesday, December 09, 2008 7:37 
PM<BR>&gt; To: users@admb-project.org<BR>&gt; Subject: Re: [ADMB Users] glitch 
in tpl2rem (and tpl2cpp) ?<BR>&gt; <BR>&gt; Download and install a current 
version of ADMB from<BR>&gt; <BR>&gt; http://admb-project.org/downloads<BR>&gt; 
<BR>&gt; Installation guides can be found at<BR>&gt; <BR>&gt; 
http://admb-project.org/documentation<BR>&gt; <BR>&gt; Let me know,<BR>&gt; 
johnoel<BR>&gt; <BR>&gt; On Dec 9, 5:53&nbsp;am, "Poos, Jan Jaap" 
&lt;janjaap.P...@wur.nl&gt; wrote:<BR>&gt; &gt; Hi,<BR>&gt; &gt;<BR>&gt; &gt; I 
found a small problem with respect to tpl2rem on linux, <BR>&gt; using <BR>&gt; 
&gt; admb-9.0.9rc2-linux64-gcc3.4. When using tpl2rem on a file on <BR>&gt; one 
of <BR>&gt; &gt; our network disks, this results in:<BR>&gt; &gt;<BR>&gt; &gt; 
sh: envpref.htp: Permission denied<BR>&gt; &gt; Error executing command 
&nbsp;sed -e " " &nbsp;classdef.tmp &gt; envpref.htp<BR>&gt; &gt; sh: 
envpref.htp: Permission denied<BR>&gt; &gt; Error executing command sed -n 
-f<BR>&gt; &gt; /home/poos001/admb-9.0.9rc2-linux64-gcc3.4/bin<BR>&gt; &gt; 
/seddf1b3 tfile2 &gt;&gt; envpref.htp<BR>&gt; &gt; sh: envpref.htp: Permission 
denied<BR>&gt; &gt; Error executing command sed -n -f<BR>&gt; &gt; 
/home/poos001/admb-9.0.9rc2-linux64-gcc3.4/bin<BR>&gt; &gt; /seddf1b4 tfile4 
&gt;&gt; envpref.htp<BR>&gt; &gt; sh: envpref.htp: Permission denied<BR>&gt; 
&gt; Error executing command sed -f<BR>&gt; &gt; 
/home/poos001/admb-9.0.9rc2-linux64-gcc3.4/bin/se<BR>&gt; &gt; ddf1b2 tfile2 
&gt;&gt; envpref.htp<BR>&gt; &gt; etc.<BR>&gt; &gt;<BR>&gt; &gt; Subsequently, 
the directory in which the tpl file is located <BR>&gt; looks like:<BR>&gt; 
&gt;<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares &nbsp; &nbsp;1894 
2008-12-09 16:36 classdef.tmp<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares 
&nbsp; &nbsp;3817 2008-12-09 16:36 <BR>&gt; envpref.cpp <BR>&gt; &gt; -rwxrwxrwx 
1 poos001 imares 6622965 2008-10-04 22:25 envpref.dat<BR>&gt; &gt; -rw-r--r-- 1 
root &nbsp; &nbsp;imares &nbsp; &nbsp;1894 2008-12-09 16:36 <BR>&gt; envpref.htp 
<BR>&gt; &gt; -rwxrwxrwx 1 poos001 imares &nbsp; &nbsp;4132 2008-10-04 22:25 
<BR>&gt; envpref.pin <BR>&gt; &gt; -rwxrwxrwx 1 poos001 imares &nbsp; &nbsp;2308 
2008-12-09 14:01 envpref.tpl<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares 
&nbsp; &nbsp; &nbsp; 0 2008-12-09 16:36 header.tmp<BR>&gt; &gt; -rw-r--r-- 1 
root &nbsp; &nbsp;imares &nbsp; &nbsp;1263 2008-12-09 16:36 tfile1<BR>&gt; &gt; 
-rw-r--r-- 1 root &nbsp; &nbsp;imares &nbsp; &nbsp; 126 2008-12-09 16:36 
tfile2<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares &nbsp; &nbsp; 383 
2008-12-09 16:36 tfile3<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares 
&nbsp; &nbsp; 122 2008-12-09 16:36 tfile4<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; 
&nbsp;imares &nbsp; &nbsp; 585 2008-12-09 16:36 xxalloc1.tmp<BR>&gt; &gt; 
-rw-r--r-- 1 root &nbsp; &nbsp;imares &nbsp; &nbsp; 179 2008-12-09 16:36 
xxalloc2.tmp<BR>&gt; &gt; -rw-r--r-- 1 root &nbsp; &nbsp;imares &nbsp; &nbsp; 
836 2008-12-09 16:36 <BR>&gt; xxalloc3.tmp <BR>&gt; &gt; -etc.<BR>&gt; 
&gt;<BR>&gt; &gt; So, all the temporary files remain in the directory. Running 
<BR>&gt; tpl2rem <BR>&gt; &gt; again results in a segmentation fault.<BR>&gt; 
&gt;<BR>&gt; &gt; This looks like a problem with setting the permissions when 
<BR>&gt; the <BR>&gt; &gt; temporary files are made. The problem disappears when 
copying <BR>&gt; the <BR>&gt; &gt; files to another location (like the users 
home dir). The same <BR>&gt; problem <BR>&gt; &gt; also disappears when running 
tpl2env as root. Maybe this can <BR>&gt; be looked <BR>&gt; &gt; into and fixed 
in a future version?<BR>&gt; &gt;<BR>&gt; &gt; Cheers, thanks in advance, Jan 
Jaap<BR>&gt; &gt;<BR>&gt; &gt; 
_______________________________________________<BR>&gt; &gt; Users mailing 
list<BR>&gt; &gt; Us...@admb-project.orghttp://lists.admb-<BR>&gt; 
project.org/mailman/listinfo/u&gt; sers<BR>&gt; 
_______________________________________________<BR>&gt; Users mailing 
list<BR>&gt; Users@admb-project.org<BR>&gt; 
http://lists.admb-project.org/mailman/listinfo/users<BR>&gt; <BR>&gt; Hi 
John,<BR>&gt; <BR>&gt; Thanks for your swift reaction. However, it appears the 
problem <BR>&gt; is not fixed, but has become worse. With v 9.0.65, tpl2rem 
fails <BR>&gt; also in a situation where it worked previously:<BR>&gt; <BR>&gt; 
poos001@D0400736:~/admb$ export ADMB_HOME=/home/poos001/admb-<BR>&gt; 
9.0.65-linux64-gcc3.4.6/<BR>&gt; poos001@D0400736:~/admb$ ./tpl2rem 
envpref<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binseddf1b3: No such file or 
directory<BR>&gt; Error executing command sed -n -f 
/home/poos001/admb-9.0.65-<BR>&gt; linux64-gcc3.4.6/binseddf1b3 tfile2 &gt;&gt; 
envpref.htp<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binseddf1b4: No such file or 
directory<BR>&gt; Error executing command sed -n -f 
/home/poos001/admb-9.0.65-<BR>&gt; linux64-gcc3.4.6/binseddf1b4 tfile4 &gt;&gt; 
envpref.htp<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binseddf1b2: No such file or 
directory<BR>&gt; Error executing command sed -f 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binseddf1b2 tfile2 &gt;&gt; 
envpref.htp<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2d: No such file or 
directory<BR>&gt; Error executing command sed -f 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2d tfile4 &gt;&gt; 
envpref.htp<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2a: No such file or 
directory<BR>&gt; Error executing command sed -f 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2a xxalloc3.tmp 
&gt;&gt; envpref.cpp<BR>&gt; sed: couldn't open file 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2c: No such file or 
directory<BR>&gt; Error executing command sed -f 
/home/poos001/admb-9.0.65-linux64-<BR>&gt; gcc3.4.6/binsedf1b2c xxalloc2.tmp 
&gt;&gt; envpref.cpp<BR>&gt; Error trying to create output file 
envpref.cpp<BR>&gt; <BR>&gt; It appears the forward slash between bin and the 
sed files has <BR>&gt; disappeared, resulting in similar issues as before, only 
now in <BR>&gt; all instances. Mind you I use x86_64 and gcc 4.3.1, with the 
<BR>&gt; files for gcc3.4.6, but I don't think this is the issue.&nbsp; <BR>&gt; 
<BR>&gt; All the files in admb-9.0.65-linux64-gcc3.4.6/bin are owned by <BR>&gt; 
poos001, and have -rwxrwxrwx permission.<BR>&gt; <BR>&gt; Kind regards, Jan 
Jaap&nbsp;&nbsp;<BR><SPAN class=234111511-10122008><FONT face=Arial 
color=#0000ff size=2>&nbsp;</FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2>-------------</FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2>Removing the trailing slash from ADMB_HOME and explicitly adding 
$ADMB_HOME/bin to the path did&nbsp;indeed return the behaviour of tpl2rem as 
previously. This means it is still not able to properly function at the 
specified location.&nbsp;Running tpl2rem results in:</FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff size=2><A 
href="mailto:poos001@D0400736:/media/n/Projecten/Computing">poos001@D0400736:/media/n/Projecten/Computing</A> 
desktop Texel/admb$ export PATH=$ADMB_HOME/bin:$PATH<BR><A 
href="mailto:poos001@D0400736:/media/n/Projecten/Computing">poos001@D0400736:/media/n/Projecten/Computing</A> 
desktop Texel/admb$ ./tpl2rem envpref<BR>sh: envpref.htp: Permission 
denied<BR>Error executing command&nbsp; sed -e " "&nbsp; classdef.tmp &gt; 
envpref.htp<BR>sh: envpref.htp: Permission denied<BR>Error executing command sed 
-n -f /home/poos001/admb-9.0.65-linux64-gcc3.4.6/bin/seddf1b3 tfile2 &gt;&gt; 
envpref.htp<BR>sh: envpref.htp: Permission denied<BR></FONT></SPAN><SPAN 
class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2>etc.</FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff size=2>he 
problem is that envpref is owned by root, and does not get write permissions by 
anybody else but root: </FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff size=2>ls -la 
envpref.htp results in:</FONT></SPAN></DIV><SPAN class=234111511-10122008><FONT>
<DIV><FONT face=Arial color=#0000ff size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial color=#0000ff size=2>-rw-r--r-- 1 root 
imares&nbsp;&nbsp;&nbsp; 1894 2008-12-10 13:18 envpref.htp<BR></FONT></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff size=2>Thus, 
appending of the&nbsp;results of sed (that is done by poos001)&nbsp;cannot be 
done because poos001 does not have permission to write the file.&nbsp;The 
problem could be solved by making sure that envpref.htp and envpref.cpp get 
permission -rw-rw-rw- when they are created. Alternatively,&nbsp;the .cpp and 
.htp file can be created somewhere&nbsp;differently and&nbsp;copied into the 
directory in one go. I realize this problem is partly&nbsp;the result of our 
hardware and using smbfs. That results in the&nbsp;owner of the file being 
"root" and not the 
current&nbsp;user.&nbsp;&nbsp;&nbsp;</FONT></SPAN></DIV></FONT></SPAN>
<DIV><SPAN class=234111511-10122008></SPAN><SPAN class=234111511-10122008><FONT 
face=Arial color=#0000ff size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2>Cheers, Jan Jaap </FONT></SPAN></DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2></FONT></SPAN>&nbsp;</DIV>
<DIV><SPAN class=234111511-10122008><FONT face=Arial color=#0000ff 
size=2>&nbsp;</DIV></FONT></SPAN></BODY></HTML>