]> git.mxchange.org Git - simgear.git/commitdiff
Sync he configure script with that one from FLightGear by splitting the LIBS cariable...
authorehofman <ehofman>
Thu, 10 Jul 2003 10:02:10 +0000 (10:02 +0000)
committerehofman <ehofman>
Thu, 10 Jul 2003 10:02:10 +0000 (10:02 +0000)
configure.ac
simgear/io/Makefile.am

index 027275e63d16c4f6038b7c235c7ec723dcf0c7e6..6c9ff9abc84a093329e10a08e8e8dbd267854985 100644 (file)
@@ -134,8 +134,6 @@ esac
 
 dnl Checks for libraries.
 
-AC_SEARCH_LIBS(cos, m)
-
 dnl Thread related checks
 AC_CHECK_HEADER(pthread.h)
 AC_CHECK_LIB(pthread, pthread_exit)
@@ -166,10 +164,22 @@ fi
 
 AM_CONDITIONAL(HAVE_THREADS, test "x$ac_cv_lib_pthread_pthread_exit" = "xyes" -a "x$ac_cv_header_pthread_h" = "xyes")
 
+thread_LIBS="$LIBS"
+LIBS=""
 
+dnl search for network related libraries
 AC_SEARCH_LIBS(inet_addr, xnet)
 AC_SEARCH_LIBS(socket, socket)
 
+network_LIBS="$LIBS"
+LIBS=""
+
+dnl check for some default libraries
+AC_SEARCH_LIBS(cos, m)
+
+base_LIBS="$LIBS"
+LIBS=""
+
 dnl check for glut location
 AC_CHECK_HEADER(GL/glut.h)
 if test "x$ac_cv_header_GL_glut_h" = "xyes"; then
@@ -184,9 +194,6 @@ else
     fi
 fi
 
-base_LIBS="$LIBS"
-LIBS=""
-
 dnl check for OpenGL related libraries
 case "${host}" in
 *-*-cygwin* | *-*-mingw32*)
@@ -252,6 +259,8 @@ LIBS="$base_LIBS"
 
 AC_SUBST(base_LIBS)
 AC_SUBST(opengl_LIBS)
+AC_SUBST(thread_LIBS)
+AC_SUBST(network_LIBS)
 
 dnl Check for MS Windows environment
 AC_CHECK_HEADER(windows.h)
index 60bf8015a84085804266e7e6436546d7bb9964c7..2c869c0a40d925e472e157f3d2665aac5b690484 100644 (file)
@@ -32,7 +32,8 @@ tcp_server_LDADD = \
        $(top_builddir)/simgear/bucket/libsgbucket.a \
        $(top_builddir)/simgear/misc/libsgmisc.a \
        $(top_builddir)/simgear/xml/libsgxml.a \
-       -lplibnet -lplibul -lz
+       -lplibnet -lplibul -lz \
+       $(network_LIBS)
 
 tcp_client_SOURCES = tcp_client.cxx
 
@@ -42,7 +43,8 @@ tcp_client_LDADD = \
        $(top_builddir)/simgear/bucket/libsgbucket.a \
        $(top_builddir)/simgear/misc/libsgmisc.a \
         $(top_builddir)/simgear/xml/libsgxml.a \
-       -lplibnet -lplibul -lz
+       -lplibnet -lplibul -lz \
+       $(network_LIBS)
 
 socktest_SOURCES = socktest.cxx
 
@@ -52,7 +54,8 @@ socktest_LDADD = \
        $(top_builddir)/simgear/debug/libsgdebug.a \
        $(top_builddir)/simgear/misc/libsgmisc.a \
        $(top_builddir)/simgear/xml/libsgxml.a \
-       -lplibnet -lplibul -lz
+       -lplibnet -lplibul -lz \
+       $(network_LIBS)
 
 lowtest_SOURCES = lowtest.cxx