ports/161431: lang/perl5.12: fix build on 10.0-CURRENT

Jilles Tjoelker jilles at stack.nl
Sun Oct 9 15:40:10 UTC 2011


>Number:         161431
>Category:       ports
>Synopsis:       lang/perl5.12: fix build on 10.0-CURRENT
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-ports-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Sun Oct 09 15:40:09 UTC 2011
>Closed-Date:
>Last-Modified:
>Originator:     Jilles Tjoelker
>Release:        FreeBSD 10.0-CURRENT i386
>Organization:
The FreeBSD Project
>Environment:
FreeBSD 10.0-CURRENT without version number hacks but with working libtool
(in my case, by having a /usr/share/mk/bsd.port.mk with a workaround
$FreeBSD: head/share/mk/bsd.port.mk 226124 2011-10-08 00:01:17Z stas $
but there are other ways to accomplish this)
>Description:
lang/perl5.12 does not build on 10.0-CURRENT.

Because of wrong version checks, it runs nm on /lib/libc.so.7 which does
not work, then tries ar and bld which do not work either.

In FreeBSD 1.x (no shared libraries), the nm command worked, and also in
a.out versions with shared libraries. For newer versions,
hints/freebsd.sh tries to disable running nm.

>How-To-Repeat:
Try to build lang/perl5.12 on the given environment.
>Fix:
Fix the version checks in hints/freebsd.sh.

I created a separate patch file patch-freebsd.sh-freebsd10 because I
expect this to go upstream fairly soon.

This patch also fixes the build of lang/perl5.10 and lang/perl5.14.

--- patch-freebsd.sh-freebsd10 begins here ---
--- hints/freebsd.sh.orig2	2011-10-09 13:30:37.000000000 +0000
+++ hints/freebsd.sh	2011-10-09 14:12:48.000000000 +0000
@@ -116,7 +116,8 @@
 case "$osvers" in
 0.*|1.0*) ;;
 
-1*|2*)	cccdlflags='-DPIC -fpic'
+1.*|2.*)
+	cccdlflags='-DPIC -fpic'
 	lddlflags="-Bshareable $lddlflags"
 	;;
 
@@ -139,7 +140,7 @@
 esac
 
 case "$osvers" in
-0*|1*|2*|3*) ;;
+0.*|1.*|2.*|3.*) ;;
 
 *)
 	ccflags="${ccflags}  -DHAS_FPSETMASK -DHAS_FLOATINGPOINT_H"
@@ -196,7 +197,7 @@
 $define|true|[yY]*)
         lc_r=`/sbin/ldconfig -r|grep ':-lc_r'|awk '{print $NF}'|sed -n '$p'`
         case "$osvers" in  
-	0*|1*|2.0*|2.1*)   cat <<EOM >&4
+	0.*|1.*|2.0*|2.1*)   cat <<EOM >&4
 I did not know that FreeBSD $osvers supports POSIX threads.
 
 Feel free to tell perlbug at perl.org otherwise.
--- patch-freebsd.sh-freebsd10 ends here ---


>Release-Note:
>Audit-Trail:
>Unformatted:



More information about the freebsd-ports-bugs mailing list