From 4852afdaf36908f4388c1d4cf10e1feeb3f044f8 Mon Sep 17 00:00:00 2001 From: Michael Jerris Date: Sun, 11 Mar 2007 10:30:12 +0000 Subject: [PATCH] some tweaks for building and linking in place before install git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4538 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- libs/js/Makefile.in | 3 ++- libs/js/configure.ac | 6 ++++-- libs/js/nsprpub/configure.in | 6 +++--- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/libs/js/Makefile.in b/libs/js/Makefile.in index a088bb9d72..5cfc0f4837 100644 --- a/libs/js/Makefile.in +++ b/libs/js/Makefile.in @@ -51,6 +51,7 @@ CLI_CFLAGS = @CLI_CFLAGS@ CLI_CPPFLAGS = @CLI_CPPFLAGS@ CLI_LDFLAGS = @CLI_LDFLAGS@ CLI_LIBS = @CLI_LIBS@ +LIBPATH = @LIBPATH@ RM = rm -f CP = cp @@ -168,7 +169,7 @@ src/perlconnect/jsperl.o: src/perlconnect/jsperl.c $(LIB_OBJS): src/jsautocfg.h src/jsautocfg.h: jscpucfg -rm -f $@ src/jsautocfg.h - $(LIBTOOL) --mode=execute ./jscpucfg >src/jsautocfg.h + $(LIBPATH) $(LIBTOOL) --mode=execute ./jscpucfg >src/jsautocfg.h jscpucfg.o: src/jscpucfg.c $(CC) $(CPPFLAGS) $(CFLAGS) -o $@ -c $< jscpucfg: jscpucfg.o diff --git a/libs/js/configure.ac b/libs/js/configure.ac index 64f40581fb..520b4f731b 100644 --- a/libs/js/configure.ac +++ b/libs/js/configure.ac @@ -169,8 +169,9 @@ AC_ARG_WITH(nspr, AC_CACHE_CHECK([whether to build with NSPR], [ac_cv_with_nspr], [ac_cv_with_nspr=no]) if test ".$ac_cv_with_nspr" = ".yes"; then sinclude(nsprpub/config/nspr.m4) - CPPFLAGS="$CPPFLAGS -DJS_THREADSAFE=1 -Insprpub/dist/include/nspr" - LDFLAGS="$LDFLAGS -L$prefix/lib -lnspr4" + CPPFLAGS="$CPPFLAGS -DJS_THREADSAFE=1 -Insprpub/dist/include/nspr -Insprpub/pr/include" + LDFLAGS="$LDFLAGS -L$prefix/lib -L./nsprpub/dist/lib -lnspr4" + LIBPATH="LD_LIBRARY_PATH=./nsprpub/dist/lib DYLD_LIBRARY_PATH=./nsprpub/dist/lib" fi AC_SUBST(CLI_CFLAGS) @@ -178,6 +179,7 @@ AC_SUBST(CLI_CPPFLAGS) AC_SUBST(CLI_LDFLAGS) AC_SUBST(CLI_LIBS) AC_SUBST(CLI_OBJS) +AC_SUBST(LIBPATH) with_tags="" sinclude(libtool.m4) diff --git a/libs/js/nsprpub/configure.in b/libs/js/nsprpub/configure.in index ea1026c9bb..a2acd93061 100644 --- a/libs/js/nsprpub/configure.in +++ b/libs/js/nsprpub/configure.in @@ -35,7 +35,7 @@ dnl may use your version of this file under either the MPL or the dnl GPL. dnl -AC_PREREQ(2.12) +AC_PREREQ(2.59) AC_INIT(config/libc_r.h) AC_CONFIG_AUX_DIR(${srcdir}/build/autoconf) @@ -405,8 +405,8 @@ if test "$target" != "$host"; then AC_MSG_CHECKING([whether the $host compiler ($HOST_CC $HOST_CFLAGS $HOST_LDFLAGS) works]) AC_TRY_COMPILE([], [return(0);], - [ac_cv_prog_host_cc_works=1 AC_MSG_RESULT([yes])], - AC_MSG_ERROR([installation or configuration problem: $host compiler $HOST_CC cannot create executables.]) ) + [ac_cv_prog_host_cc_works=1; AC_MSG_RESULT([yes])], + [AC_MSG_ERROR([installation or configuration problem: $host compiler $HOST_CC cannot create executables.])] ) CC=$_SAVE_CC CFLAGS=$_SAVE_CFLAGS