2c49d2bc15
Fix a build issue for Darwin. Bump PKGREVISION.
43 lines
1.8 KiB
Text
43 lines
1.8 KiB
Text
$NetBSD: patch-aa,v 1.7 2005/05/12 17:53:29 kristerw Exp $
|
|
|
|
--- configure.orig Fri Mar 11 10:32:56 2005
|
|
+++ configure Wed May 11 20:49:48 2005
|
|
@@ -42,7 +42,7 @@
|
|
USER=${USER-`whoami 2>/dev/null`}
|
|
MACHINE=`script/harch`
|
|
case $MACHINE in
|
|
- powerpc-Darwin[56]) CCC=${CC-cc};;
|
|
+ powerpc-Darwin*) CCC=gcc;;
|
|
*) CCC=${CC-gcc};;
|
|
esac
|
|
PWD=`pwd`
|
|
@@ -382,13 +382,13 @@
|
|
if $CCC -o curses curses.c >/dev/null 2>/dev/null
|
|
then CURSES=""
|
|
else
|
|
- if $CCC -o curses curses.c -lncurses >/dev/null 2>/dev/null
|
|
+ if $CCC $LDFLAGS -o curses curses.c -lncurses >/dev/null 2>/dev/null
|
|
then CURSES="-lncurses"
|
|
else
|
|
- if $CCC -o curses curses.c -lcurses >/dev/null 2>/dev/null
|
|
+ if $CCC $LDFLAGS -o curses curses.c -lcurses >/dev/null 2>/dev/null
|
|
then CURSES="-lcurses"
|
|
else
|
|
- if $CCC -o curses curses.c -lcurses -ltermcap >/dev/null 2>/dev/null
|
|
+ if $CCC $LDFLAGS -o curses curses.c -lcurses -ltermcap >/dev/null 2>/dev/null
|
|
then CURSES="-lcurses -ltermcap"
|
|
else CURSES="-ltermcap -lcurses" # don't know a good default?
|
|
fi
|
|
@@ -405,10 +405,10 @@
|
|
|
|
echo -n "Testing for the readline library: "
|
|
echo 'main(){readline();}' >rd.c
|
|
- if ${CCC} -o rd.out rd.c -lreadline >/dev/null 2>&1
|
|
+ if ${CCC} ${LDFLAGS} -o rd.out rd.c -lreadline >/dev/null 2>&1
|
|
then echo ' -lreadline (detected)'
|
|
READLINE="-DUSE_READLINE=1 -lreadline"
|
|
- else if ${CCC} -o rd.out rd.c -lreadline $CURSES >/dev/null 2>&1
|
|
+ else if ${CCC} ${LDFLAGS} -o rd.out rd.c -lreadline $CURSES >/dev/null 2>&1
|
|
then echo " -lreadline $CURSES (detected)"
|
|
READLINE="-DUSE_READLINE=1 -lreadline $CURSES"
|
|
else echo ' no (detected)'
|