?? configure.in
字號(hào):
dnl# -*- sh -*-dnl# the "configure" script is made from this by running GNU "autoconf"dnl#dnl# "$Id: configure.in,v 1.2 2003/09/08 19:28:48 jasonk Exp $"dnl#dnl# Configuration script for ViewMLdnl#dnl# Copyright 2000 by Century Software Embedded Technologies.dnl#dnl# This library is free software; you can redistribute it and/ordnl# modify it under the terms of the GNU Library General Publicdnl# License as published by the Free Software Foundation; eitherdnl# version 2 of the License, or (at your option) any later version.dnl#dnl# This library is distributed in the hope that it will be useful,dnl# but WITHOUT ANY WARRANTY; without even the implied warranty ofdnl# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNUdnl# Library General Public License for more details.dnl#dnl# You should have received a copy of the GNU Library General Publicdnl# License along with this library; if not, write to the Free Softwarednl# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307dnl# USA.dnl#AC_INIT(src/Fl.cxx)AC_PROG_RANLIBdnl# This config script was previously very cross-compiler unfriendlydnl# so we changed the LIBCOMMAND from the whole command to just thednl# arguments provided to the $AR directory elsewhereLIBNAME="libfltk.a"if test "$RANLIB" != ":"; then LIBCOMMAND="cr"else LIBCOMMAND="crs"fiDSOCOMMAND="echo"DSONAME=""dnl# Get the operating system and version number...uname=`uname`uversion=`uname -r | sed -e 's/-.*$//g;s/\.//g'`dnl# uversion=`uname -r | sed -e '1,$s/[[-.A-Za-z]]//g'`if test "$uname" = "IRIX64"; then uname="IRIX"fidnl# Clear debugging flags and only enable debugging if the user asks fordnl# it.DEBUGFLAG=""PICFLAG=0CFLAGS="${CFLAGS:=}"CXXFLAGS="${CXXFLAGS:=}"AC_ARG_ENABLE(debug, [ --enable-debug turn on debugging [default=no]],[if eval "test x$enable_debug = xyes"; then DEBUGFLAG="-g "fi])AC_ARG_ENABLE(shared, [ --enable-shared turn on shared libraries [default=no]],[if eval "test x$enable_shared = xyes"; then PICFLAG=1 case $uname in SunOS* | UNIX_S*) DSONAME="libfltk.so.1" DSOCOMMAND="\$(CXX) -Wl,-h,libfltk.so.1 \$(LDLIBS) -G $DEBUGFLAG -o" ;; DSONAME="libfltk.sl.1" DSOCOMMAND="ld -b -z +h libfltk.sl.1 $DEBUGFLAG -o" ;; OSF1*) DSONAME="libfltk.so.1" DSOCOMMAND="\$(CXX) -Wl,-soname,libfltk.so.1 \$(LDLIBS) -shared $DEBUGFLAG -o" ;; IRIX*) DSONAME="libfltk.so.1" DSOCOMMAND="\$(CXX) -soname libfltk.so.1 \$(LDLIBS) -shared $DEBUGFLAG -o" ;; *) echo "Warning: shared libraries may not be supported. Trying -shared" echo " option with compiler." DSONAME="libfltk.so.1" DSOCOMMAND="\$(CXX) -Wl,-soname,libfltk.so.1 \$(LDLIBS) -shared $DEBUGFLAG -o" ;; esacfi])AC_PROG_CCAC_PROG_CXXdnl# AC_PROG_INSTALLAC_C_BIGENDIANAC_CHECK_SIZEOF(short, 2)AC_CHECK_SIZEOF(int, 4)AC_CHECK_SIZEOF(long, 4)if test $ac_cv_sizeof_short -eq 2; then AC_DEFINE(U16,unsigned short)fiif test $ac_cv_sizeof_int -eq 4; then AC_DEFINE(U32,unsigned)else if test $ac_cv_sizeof_long -eq 4; then AC_DEFINE(U32,unsigned long) fifiif test $ac_cv_sizeof_int -eq 8; then AC_DEFINE(U64,unsigned)else if test $ac_cv_sizeof_long -eq 8; then AC_DEFINE(U64,unsigned long) fifiAC_HEADER_DIRENTAC_CHECK_HEADER(sys/select.h)AC_CHECK_FUNC(scandir, if test "$uname" = "SunOS"; then echo Not using Solaris scandir BSD emulation function. else AC_DEFINE(HAVE_SCANDIR) fi)AC_CHECK_FUNC(vsnprintf, if test "$uname" = "HP-UX" -a "$uversion" = "1020"; then echo Not using built-in vsnprintf function because you are running HP-UX 10.20. else AC_DEFINE(HAVE_VSNPRINTF) fi)AC_CHECK_FUNC(snprintf, if test "$uname" = "HP-UX" -a "$uversion" = "1020"; then echo Not using built-in snprintf function because you are running HP-UX 10.20. else AC_DEFINE(HAVE_SNPRINTF) fi)AC_CHECK_FUNCS(vsprintf)dnl# X Windows stuff moved below to accomodate MicroWindows as welldnl# This will allow us to have Nano-X or X supportMICROWINFOLDER=""NANOX=0AC_ARG_WITH(microwin, [ --with-microwin=[microwindows base path] Uses MicroWindows instead of X (specify path)], [ echo "Using MicroWindows instead of X..." MICROWINFOLDER=$with_microwin if test -d $MICROWINFOLDER/include/microwin; then MWINCLUDES="-I$MICROWINFOLDER/include -I$MICROWINFOLDER/include/microwin" else MWINCLUDES="-I$MICROWINFOLDER/include" fi NANOX=1 CFLAGS="$CFLAGS -DNANO_X $MWINCLUDES -DNANOXFOLDER='\"$MICROWINFOLDER/bin\"'" CXXFLAGS="$CXXFLAGS -DNANO_X $MWINCLUDES -DNANOXFOLDER='\"$MICROWINFOLDER/bin\"'"# MWLIBS="-L$MICROWINFOLDER/lib -lnano-X -lmwengine -lmwdrivers -lmwfonts -ljpeg" MWLIBS="-L$MICROWINFOLDER/lib -lnano-X" LDFLAGS="$LDFLAGS -DNANO_X=1" ])AC_SUBST(MICROWINFOLDER)AC_SUBST(NANOX)AC_SUBST(MWLIBS)AC_ARG_WITH(xdrivers, [ --with-xdrivers Specifies where the X drivers for Microwindows are ],[ NANOX=0])dnl# If we have already asked for NanoX, then wednl# should be able to skip over thisif [ test $NANOX = 0 ]; then echo "No MicroWindows specified, checking for X libraries..." AC_PATH_XTRA echo "Ignoring libraries \"$X_PRE_LIBS\" requested by configure." dnl# LIBS="$LIBS$X_LIBS$X_PRE_LIBS" LIBS="$LIBS$X_LIBS" CFLAGS="$CFLAGS $X_CFLAGS" CPPFLAGS="$CPPFLAGS $X_CFLAGS" dnl# My test to see if OpenGL is on this machine: GLLIB= AC_CHECK_LIB(GL, glXMakeCurrent, AC_DEFINE(HAVE_GL) GLLIB=" -lGLU -lGL", \ AC_CHECK_LIB(MesaGL,glXMakeCurrent, AC_DEFINE(HAVE_GL) GLLIB=" -lMesaGLU -lMesaGL",,\ -lX11 -lXext $X_EXTRA_LIBS -lm), \ -lX11 -lXext $X_EXTRA_LIBS -lm) AC_SUBST(GLLIB) AC_CHECK_HEADER(X11/extensions/Xdbe.h, \ if test "$uname" != "SunOS"; then AC_DEFINE(HAVE_XDBE) fi) AC_CACHE_CHECK("for X overlay visuals", ac_cv_have_overlay, if xprop -root 2>/dev/null | grep -c "SERVER_OVERLAY_VISUALS" >/dev/null; then ac_cv_have_overlay=yes else ac_cv_have_overlay=no fi) if test "$ac_cv_have_overlay" = yes; then AC_DEFINE(HAVE_OVERLAY) fifiMAKEDEPEND="\$(CXX) -M"dnl# add warnings to compiler switches:dnl# do this last so messing with switches does not break testsif test -n "$GXX"; then CFLAGS="-Wall $CFLAGS" CXXFLAGS="-Wall -Wno-return-type $CXXFLAGS" if test -z "$DEBUGFLAG"; then CFLAGS="-O2 $CFLAGS" CXXFLAGS="-O2 $CXXFLAGS" fi if test $PICFLAG = 1; then CFLAGS="-fPIC $CFLAGS" CXXFLAGS="-fPIC $CXXFLAGS" fielse case `(uname) 2>/dev/null` in IRIX*) # Running some flavor of IRIX; see which version and # set things up according... if test "$uversion" -ge 62; then # We are running IRIX 6.2 or higher; uncomment the following # lines if you don't have IDO 7.2 or higher: # # CXX="CC -n32" # CC="cc -n32" # LD="ld -n32" # MAKEDEPEND="CC -M" echo "FOR BEST RESULTS BEFORE COMPILING: setenv SGI_ABI -n32" # -woff 3322 is necessary due to errors in Xlib headers on IRIX CFLAGS="-fullwarn $CFLAGS" CXXFLAGS="-fullwarn -woff 1685,3322 $CXXFLAGS" else CXXFLAGS="+w +pp $CXXFLAGS" fi if test -z "$DEBUGFLAG"; then CFLAGS="-O2 $CFLAGS" CXXFLAGS="-O2 $CXXFLAGS" fi ;; HP-UX*) # Running HP-UX; these options should work for the HP compilers. if test -z "$DEBUGFLAG"; then CFLAGS="+O2 $CFLAGS" CXXFLAGS="+O2 +W336,501,736,740,749,829 $CXXFLAGS" fi ;; SunOS*) # Solaris if test -z "$DEBUGFLAG"; then CFLAGS="-O" CXXFLAGS="-O" fi if test $PICFLAG = 1; then CFLAGS="-KPIC $CFLAGS" CXXFLAGS="-PIC $CXXFLAGS" fi ;; *) # Running some other operating system; inform the user they # should contribute the necessary options to fltk-bugs@easysw.com... echo "Building FLTK with default compiler optimizations; contact" echo "fltk-bugs@easysw.com with uname and compiler options needed" echo "for your platform, or set the CFLAGS and CXXFLAGS options" echo "before running configure." ;; esacfiCFLAGS="$DEBUGFLAG $CFLAGS"CXXFLAGS="$DEBUGFLAG $CXXFLAGS"AC_SUBST(DSONAME)AC_SUBST(DSOCOMMAND)AC_SUBST(LIBNAME)AC_SUBST(LIBCOMMAND)AC_SUBST(MAKEDEPEND)AC_CONFIG_HEADER(config.h:configh.in)AC_OUTPUT(makeinclude)dnl#dnl# End of "$Id: configure.in,v 1.2 2003/09/08 19:28:48 jasonk Exp $".dnl#
?? 快捷鍵說(shuō)明
復(fù)制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號(hào)
Ctrl + =
減小字號(hào)
Ctrl + -