ports/125974: building games/xpuyopuyo fails

Tsurutani Naoki turutani at scphys.kyoto-u.ac.jp
Sat Jul 26 10:30:06 UTC 2008


>Number:         125974
>Category:       ports
>Synopsis:       building games/xpuyopuyo fails
>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:   Sat Jul 26 10:30:05 UTC 2008
>Closed-Date:
>Last-Modified:
>Originator:     Tsurutani Naoki
>Release:        FreeBSD 7.0-STABLE i386
>Organization:
>Environment:
System: FreeBSD h120.65.226.10.32118.vlan.kuins.net 7.0-STABLE FreeBSD 7.0-STABLE #15: Sun Jul 20 21:06:33 JST 2008 turutani at h120.65.226.10.32118.vlan.kuins.net:/usr/local/work/usr/obj/usr/src/sys/POLYMER i386


	
>Description:
	building ports/games/xpuyopuyo fails when audio/libmikmod is installed.
	
>How-To-Repeat:
	% ls -d /var/db/pkg/libmikmod*
	libmikmod-esound-3.1.11_2
	% cd /usr/ports/games/xpuyopuyo
	...
	cc -DHAVE_CONFIG_H -I. -I. -I. -Ipgame -Ipai -Ipnet    -O2 -fno-strict-aliasing -pipe -O2 -fno-strict-aliasing -pipe -Wall -Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1 -O2 -fno-strict-aliasing \
	-pipe -Wall -Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1 -O2 -fno-strict-aliasing -pipe -Wall -Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1 -c xpuyopuyo.c
	/bin/sh ./libtool --mode=link cc  -O2 -fno-strict-aliasing -pipe -O2 -fno-strict-aliasing -pipe -Wall -Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1 -O2 -fno-strict-aliasing -pipe -Wall \
	-Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1 -O2 -fno-strict-aliasing -pipe -Wall -Wpointer-arith -DMIKMOD=1 -DGTK=1 -DHAVE_GETOPT_H=1  -o xpuyopuyo  xpuyopuyo.o  pgame/libxpp_game.a pai/libxpp_ai.a \
	pgtk/libxpp_interface.a pnet/libxpp_net.a         -L/usr/local/lib -lmikmod -pthread -L/usr/local/lib -lm psound/libxpp_sound.a -L/usr/local/lib -L/usr/local/lib -lgtk-12 -lgdk-12 -lgmodule-12 -lglib-12 \
	-lintl -lXi -lXext -lX11 -lm pgame/libxpp_game.a putil/libxpp_util.a -lXpm -lX11
	mkdir .libs
	libtool: link: cannot find the library `'
	...
	
>Fix:
	xpuyopuyo always try to use libmikmod even if WITHOUT_MIKMOD is set to 1.
	libmikmod-config returns "-pthread", and libtool in xpuyopuyo cannot
	treat it correctly.
	here is a patch:

--- ltmain.sh.orig	2008-07-26 17:06:14.000000000 +0900
+++ ltmain.sh	2008-07-26 17:06:24.000000000 +0900
@@ -1710,6 +1710,38 @@
 	lib=
 	found=no
 	case $deplib in
+        -mt|-mthreads|-kthread|-Kthread|-pthread|-pthreads|--thread-safe|-threads)
+          if test "$linkmode,$pass" = "prog,link"; then
+            compile_deplibs="$deplib $compile_deplibs"
+            finalize_deplibs="$deplib $finalize_deplibs"
+          else
+            compiler_flags="$compiler_flags $deplib"
+          fi
+
+          case $linkmode in
+          lib)
+            deplibs="$deplib $deplibs"
+            test "$pass" = conv && continue
+            newdependency_libs="$deplib $newdependency_libs"
+            ;;
+          prog)
+            if test "$pass" = conv; then
+              deplibs="$deplib $deplibs"
+              continue
+            fi
+            if test "$pass" = scan; then
+              deplibs="$deplib $deplibs"
+            else
+              compile_deplibs="$deplib $compile_deplibs"
+              finalize_deplibs="$deplib $finalize_deplibs"
+            fi
+            ;;
+          *)
+            ;;
+          esac # linkmode
+
+          continue
+          ;;
 	-l*)
 	  if test $linkmode != lib && test $linkmode != prog; then
 	    $echo "$modename: warning: \`-l' is ignored for archives/objects" 1>&2

	this patch can be stored as files/patch-ac.
	this is merely taken from recent libtool.


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



More information about the freebsd-ports-bugs mailing list