Bug 3282 - /sbin/mount.smbfs symlink problem with $DESTDIR
/sbin/mount.smbfs symlink problem with $DESTDIR
Status: RESOLVED FIXED
Product: Samba 3.0
Classification: Unclassified
Component: Packaging
3.0.20b
Other Linux
: P3 normal
: none
Assigned To: Lars Müller
Samba QA Contact
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-11-24 08:25 UTC by Vincent Fretin
Modified: 2006-02-22 15:41 UTC (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vincent Fretin 2005-11-24 08:25:43 UTC
There is a problem when I "make install DESTDIR=/build", to create a package and after I install it in /.
/sbin/mount.smbfs linked to /build/usr/bin/smbmount
This symlink should linked to /usr/bin/smbmount
I investigate a little, the problem seems to be in
source/script/installbin.sh line 31
ln -sf $BINDIR/$p2 $DESTDIR/sbin/mount.smbfs
I have a suggestion:
ln -sf `echo $BINDIR|sed "s@$DESTDIR@@"`/$p2 $DESTDIR/sbin/mount.smbfs
What do you think about it?
Comment 1 Gerald (Jerry) Carter 2006-01-25 05:59:03 UTC
This is usually fixed in the packaging scripts, not 
in make install.  In fact, the line you site in Samba's 
install scripts was the direct result of anotehr bug 
report.
Comment 2 Lars Müller 2006-02-22 15:08:22 UTC
I'm so sorry DuDE.  This is a real bug. :)
Comment 3 Lars Müller 2006-02-22 15:41:32 UTC
Thanks Vincent for the analysis.  But the problem is also one level above in the calling Makefile.  We pass DESTDIR while making the installbin rule as second arg to script/installbin.sh.  But we _also_ prepend DESTDIR to each DIR we pass.  This was required as we never used DESTDIR in script/installbin.sh while we installed the binaries.  At the moment we only used it for the sym link of mount.smbfs.

Fixed with subversion revision 13642.