[Vorbis-dev] patches for xiph build setup

Glenn Maynard glenn
Thu Jun 10 11:40:34 PDT 2004


On Thu, Jun 10, 2004 at 05:39:10PM +0200, Thomas Vander Stichele wrote:
> http://thomas.apestaart.org/download/patches/vorbis/

I looked quickly to see if an issue I fixed happened to be included
(it's not; patch below), and I'm a little confused: all of the
"AUTOMAKE_OPTIONS = foreign" commands were removed, and there's no
ChangeLog entry explaining it.  That causes errors like "required file
`./NEWS' not found".

The attached patch fixes a problem I hit: CFLAGS and LDFLAGS specified
by the user ("CFLAGS=-opt ./configure") are being doubled up, which
caused my build to fail.

--
Glenn Maynard
-------------- next part --------------
Index: configure.in
===================================================================
--- configure.in	(revision 6820)
+++ configure.in	(working copy)
@@ -71,8 +71,6 @@

dnl Set some target options

-cflags_save="$CFLAGS"
-ldflags_save="$LDFLAGS"
if test -z "$GCC"; then
case $host in
*-*-irix*)
@@ -82,15 +80,15 @@
CC=cc
fi
DEBUG="-g -signed"
-		CFLAGS="-O2 -w -signed"
+		CFLAGS=${CFLAGS}" -O2 -w -signed"
PROFILE="-p -g3 -O2 -signed" ;;
sparc-sun-solaris*)
DEBUG="-v -g"
-		CFLAGS="-xO4 -fast -w -fsimple -native -xcg92"
+		CFLAGS=${CFLAGS} "-xO4 -fast -w -fsimple -native -xcg92"
PROFILE="-v -xpg -g -xO4 -fast -native -fsimple -xcg92 -Dsuncc" ;;
*)
DEBUG="-g"
-		CFLAGS="-O"
+		CFLAGS=${CFLAGS}" -O"
PROFILE="-g -p" ;;
esac
else
@@ -98,7 +96,7 @@
case $host in
*86-*-linux*)
DEBUG="-g -Wall -W -D_REENTRANT -D__NO_MATH_INLINES -fsigned-char"
-		CFLAGS="-O20 -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char"
+		CFLAGS=${CFLAGS}" -O20 -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char"
#              	PROFILE="-Wall -W -pg -g -O20 -ffast-math -D_REENTRANT -fsigned-char -fno-inline -static"
PROFILE="-Wall -W -pg -g -O20 -ffast-math -mno-ieee-fp -D_REENTRANT -fsigned-char -fno-inline"

@@ -138,33 +136,31 @@
AC_MSG_WARN([********************************************************])
AC_MSG_WARN([                                                        ])

-  		CFLAGS=${OPT}" -D__NO_MATH_INLINES"
+  		CFLAGS=${CFLAGS}" "${OPT}" -D__NO_MATH_INLINES"
PROFILE=${PROFILE}" -D__NO_MATH_INLINES"
fi;;
powerpc-*-linux*)
DEBUG="-g -Wall -W -D_REENTRANT -D__NO_MATH_INLINES"
-		CFLAGS="-O3 -ffast-math -mfused-madd -mcpu=750 -D_REENTRANT"
+		CFLAGS=${CFLAGS} "-O3 -ffast-math -mfused-madd -mcpu=750 -D_REENTRANT"
PROFILE="-pg -g -O3 -ffast-math -mfused-madd -mcpu=750 -D_REENTRANT";;
*-*-linux*)
DEBUG="-g -Wall -W -D_REENTRANT -D__NO_MATH_INLINES -fsigned-char"
-		CFLAGS="-O20 -ffast-math -D_REENTRANT -fsigned-char"
+		CFLAGS=${CFLAGS} "-O20 -ffast-math -D_REENTRANT -fsigned-char"
PROFILE="-pg -g -O20 -ffast-math -D_REENTRANT -fsigned-char";;
sparc-sun-*)
DEBUG="-g -Wall -W -D__NO_MATH_INLINES -fsigned-char -mv8"
-		CFLAGS="-O20 -ffast-math -D__NO_MATH_INLINES -fsigned-char -mv8"
+		CFLAGS=${CFLAGS} "-O20 -ffast-math -D__NO_MATH_INLINES -fsigned-char -mv8"
PROFILE="-pg -g -O20 -D__NO_MATH_INLINES -fsigned-char -mv8" ;;
*-*-darwin*)
DEBUG="-DDARWIN -fno-common -force_cpusubtype_ALL -Wall -g -O0 -fsigned-char"
-		CFLAGS="-DDARWIN -fno-common -force_cpusubtype_ALL -Wall -g -O4 -ffast-math -fsigned-char"
+		CFLAGS=${CFLAGS} "-DDARWIN -fno-common -force_cpusubtype_ALL -Wall -g -O4 -ffast-math -fsigned-char"
PROFILE="-DDARWIN -fno-common -force_cpusubtype_ALL -Wall -g -pg -O4 -ffast-math -fsigned-char";;
*)
DEBUG="-g -Wall -W -D__NO_MATH_INLINES -fsigned-char"
-		CFLAGS="-O20 -D__NO_MATH_INLINES -fsigned-char"
+		CFLAGS=${CFLAGS} "-O20 -D__NO_MATH_INLINES -fsigned-char"
PROFILE="-O20 -g -pg -D__NO_MATH_INLINES -fsigned-char" ;;
esac
fi
-CFLAGS="$CFLAGS $cflags_save"
-LDFLAGS="$LDFLAGS $ldflags_save"

dnl --------------------------------------------------
dnl Check for headers


More information about the Vorbis-dev mailing list