ports/115988: converters/libiconv port doesn't handle PREFIX well

Markus Hitter mah at jump-ing.de
Mon Sep 3 19:30:08 PDT 2007


The following reply was made to PR ports/115988; it has been noted by GNATS.

From: Markus Hitter <mah at jump-ing.de>
To: Jeremy Messenger <mezz7 at cox.net>,
 bug-followup at freebsd.org
Cc:  
Subject: Re: ports/115988: converters/libiconv port doesn't handle PREFIX well
Date: Tue, 4 Sep 2007 04:20:23 +0200

 --Apple-Mail-67-111825667
 Content-Transfer-Encoding: 7bit
 Content-Type: text/plain;
 	charset=US-ASCII;
 	delsp=yes;
 	format=flowed
 
 
 Jeremy,
 
 while the original thing was probably an outdated package, the build  
 failure on a clean system with PREFIX remains. As my solution (I  
 found one) might not be the favourite of everyone, what mailing lists  
 would you recommend to discuss such things?
 
 
 Am 04.09.2007 um 01:25 schrieb Jeremy Messenger:
 
 > When you want to install a port in different PREFIX, you have to  
 > run 'make depends' first then 'make PREFIX=/usr install' second.
 
 This works, but it's documented differently (or incomplete):
 
 <http://www.freebsd.org/doc/en_US.ISO8859-1/books/handbook/ports- 
 using.html>
 
 (Section 4.5.2.1)
 
 
 Even more odd is, the port attempts to do the right thing, but fails.
 
 /usr/ports/Mk/bsd.port.mk says:
 
    # PREFIX                - Where *this* port installs its files.
 
 Accordingly, the dependencies should be installed without PREFIX.  
 However, this variable is maintained when installing dependencies.
 
 So, after a lengthy debugging session, I found a (2 line-)patch which  
 produces a behavior as documented, at least in my case:
 
 
 --Apple-Mail-67-111825667
 Content-Transfer-Encoding: 7bit
 Content-Type: application/octet-stream;
 	x-unix-mode=0644;
 	name=patch
 Content-Disposition: attachment;
 	filename=patch
 
 --- usr-ports-Mk-bsd.port.mk    2007-09-04 03:50:14.000000000 +0200
 +++ usr-ports-Mk-bsd.port.mk.patched    2007-09-04 03:48:50.000000000 +0200
 @@ -4813,10 +4813,10 @@
                                 ${ECHO_MSG} "===>   Installing existing package $${subpkgfile}"; \
                                 ${PKG_ADD} $${subpkgfile}; \
                         else \
 -                         (cd $$dir; ${MAKE} -DINSTALLS_DEPENDS $$target $$depends_args) ; \
 +                         (cd $$dir; ${MAKE} PREFIX=${LOCALBASE} -DINSTALLS_DEPENDS $$target $$depends_args) ; \
                         fi; \
                 else \
 -                       (cd $$dir; ${MAKE} -DINSTALLS_DEPENDS $$target $$depends_args) ; \
 +                       (cd $$dir; ${MAKE} PREFIX=${LOCALBASE} -DINSTALLS_DEPENDS $$target $$depends_args) ; \
                 fi; \
                 ${ECHO_MSG} "===>   Returning to build of ${PKGNAME}";
  
 
 
 --Apple-Mail-67-111825667
 Content-Transfer-Encoding: 7bit
 Content-Type: text/plain;
 	charset=US-ASCII;
 	delsp=yes;
 	format=flowed
 
 
 
 > In your other email, you said about that you have used portsnap to  
 > update your ports tree. Perhaps, it has been fixed by something  
 > wrong with previous tree?
 
 Another workaround around the unpatched build system is to build the  
 thing twice, like: make install clean && make deinstall && make  
 PREFIX=/usr install
 This probably happened as I tried a few things to make the tinybsd  
 script happy.
 
 > I am going to let you play with it a bit. If you don't get any  
 > problem, let me know and I can safe close this PR.
 
 Looks like it's a build system thing now. While I'm hacking Unix  
 systems for some 15 years now, I have a fear with this new-to-me  
 FreeBSD: What, if the misbehaviour of today vanishes tomorrow?
 
 
 Cheers,
 Markus
 
 - - - - - - - - - - - - - - - - - - -
 Dipl. Ing. Markus Hitter
 http://www.jump-ing.de/
 
 
 
 
 
 --Apple-Mail-67-111825667--


More information about the freebsd-gnome mailing list