root/juggler/branches/2.2/modules/vrjuggler/plugins/configure.ac

Revision 20711, 10.1 kB (checked in by patrick, 1 year ago)

More version number updates. These a minor (and probably unnoticed by everyone
but me), but I can't let them slip by.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1 # ************** <auto-copyright.pl BEGIN do not edit this line> **************
2 #
3 # VR Juggler is (C) Copyright 1998-2007 by Iowa State University
4 #
5 # Original Authors:
6 #   Allen Bierbaum, Christopher Just,
7 #   Patrick Hartling, Kevin Meinert,
8 #   Carolina Cruz-Neira, Albert Baker
9 #
10 # This library is free software; you can redistribute it and/or
11 # modify it under the terms of the GNU Library General Public
12 # License as published by the Free Software Foundation; either
13 # version 2 of the License, or (at your option) any later version.
14 #
15 # This library is distributed in the hope that it will be useful,
16 # but WITHOUT ANY WARRANTY; without even the implied warranty of
17 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
18 # Library General Public License for more details.
19 #
20 # You should have received a copy of the GNU Library General Public
21 # License along with this library; if not, write to the
22 # Free Software Foundation, Inc., 59 Temple Place - Suite 330,
23 # Boston, MA 02111-1307, USA.
24 #
25 # *************** <auto-copyright.pl END do not edit this line> ***************
26
27 # -----------------------------------------------------------------------------
28 # Base configure.in for VRJ plug-ins.
29 # -----------------------------------------------------------------------------
30 # This file is "compiled" by GNU autoconf to generate the configure script
31 # that is actually run.
32 # -----------------------------------------------------------------------------
33
34 AC_INIT([VR Juggler Plug-Ins], [2.2], [vrjuggler-devel@lists.sourceforge.net])
35 AC_PREREQ([2.53])
36 AC_COPYRIGHT([VR Juggler is (C) Copyright 1998-2007 by Iowa State University])
37 AC_CONFIG_SRCDIR([Makefile.in])
38 AC_REVISION($Revision$)
39 AC_CONFIG_AUX_DIR([../../../share/config])
40 DPP_PREREQ([2.1.2])
41 DPP_INIT
42
43 # -----------------------------------------------------------------------------
44 # Command-line arguments (--enable-option, --with-pkg=package_name).
45 # -----------------------------------------------------------------------------
46
47 # ------------------------------------------------------ #
48 # --enable-feature[=arg] and --disable-feature arguments #
49 # ------------------------------------------------------ #
50
51 DPP_STD_CPP(yes)
52
53 # -------------------------------------------- #
54 # --with-pkg[=arg] and --without-pkg arguments #
55 # -------------------------------------------- #
56
57 # Allow forcing the use of GCC as the compiler.
58 DPP_WITH_GCC(no)
59
60 # Define the binary format.
61 DPP_ABI_SETUP
62
63 # -----------------------------------------------------------------------------
64 # System-dependent stuff.
65 # -----------------------------------------------------------------------------
66 DPP_SYSTEM_SETUP
67
68 # Depending on the target operating system, set various command options and
69 # such.
70 case $target_os in
71     # SGI running IRIX 6.*.
72     irix6*)
73         if test "x$USE_GCC" != "xyes" ; then
74             DBG_FLAGS="$DBG_FLAGS -gslim"
75         fi
76         ;;
77 esac
78
79 # -----------------------------------------------------------------------------
80 # Path setup.
81 # -----------------------------------------------------------------------------
82 DPP_WIN32_SETUP
83
84 # $srcdir is the root directory of the juggler source tree.  To get a value for
85 # $PLUGIN_ROOT_ABS, we cd there and save the value of running pwd.  Then
86 # return to the directory where configure is being run ($topdir).
87 cd "$srcdir"
88 PLUGIN_ROOT_ABS=`pwd`
89
90 cd "$PLUGIN_ROOT_ABS/../../.."
91 UNIX_JUGGLERROOT_ABS=`pwd`
92 cd "$topdir"
93
94 if test "x$CYGPATH" != "xno" ; then
95    JUGGLERROOT_ABS=`cygpath -w "$UNIX_JUGGLERROOT_ABS" | sed -e 's/\\\\/\\//g'`
96 else
97    JUGGLERROOT_ABS="$UNIX_JUGGLERROOT_ABS"
98 fi
99
100 # -----------------------------------------------------------------------------
101 # Checks for programs.
102 # -----------------------------------------------------------------------------
103 VJ_COMPILER_SETUP
104 VJ_PROG_CC_PROF_FLAG(yes)
105 VJ_PROG_CXX_PROF_FLAG(yes)
106
107 # Ensure that the C++ compiler we've found is capable of compiling the newer
108 # newer C++ features that we need.
109 DPP_CXX_NAMESPACE([AC_MSG_ERROR([*** VRJ plug-ins require C++ namespace support ***])])
110 DPP_CXX_HAVE_STD
111 DPP_CXX_STATIC_CAST([AC_MSG_ERROR([*** VRJ plug-ins require C++ static_cast<> ***])])
112 DPP_CXX_DYNAMIC_CAST([AC_MSG_ERROR([*** VRJ Juggler plug-ins require C++ dynamic_cast<> ***])])
113
114 # Check for the JDK.
115 DPP_PATH_JAVA
116
117 # If there is still no value in $JAVAC, then warn that the GUI will not be
118 # built.
119 if test "x$JAVAC" = "xno" ; then
120     AC_MSG_WARN([*** Performance Monitor JavaBean requires javac -- it will not be built ***])
121     BUILD_JAVA='N'
122 else
123     BUILD_JAVA='Y'
124 fi
125
126 ANT="JAVA_HOME=\"$JDK_HOME\" \"$UNIX_JUGGLERROOT_ABS/external/ant/bin/ant\" --noconfig"
127
128 # Ensure that a version of Perl greater than or equal to 5.004 is available.
129 DPP_HAVE_GNU_MAKE([3.78], ,
130     [AC_MSG_ERROR([*** The build system requires GNU make 3.78 or newer ***])])
131 DPP_PERL_VER([5.004], , , [AC_MSG_ERROR([*** Perl is required ***])])
132 DPP_BASIC_PROGS([$PLATFORM], [$OS_TYPE])
133 DPP_PROG_INSTALL
134 DPP_PROG_LINKER
135
136 # -----------------------------------------------------------------------------
137 # Checks for libraries.
138 # -----------------------------------------------------------------------------
139 vrj_version='2.1.15'
140 jccl_version='1.1.5'
141 VRJUGGLER_PATH([$vrj_version], [test_tweek_cxx='Y'],
142    [AC_MSG_WARN([*** VRJ C++ API required for VRJ C++ plug-ins ***])
143     test_tweek_cxx='N'
144    ])
145
146 VPR_PATH([1.1.23], , [AC_MSG_ERROR([*** VPR required for plugins ***])])
147
148 min_tweek_version='1.1.10'
149 if test "x$test_tweek_cxx" = "xY" ; then
150    TWEEK_PATH_CXX([$min_tweek_version], [HAVE_TWEEK_CXX='Y'],
151       [AC_MSG_WARN([*** Tweek C++ API required for performance monitoring ***])
152        HAVE_TWEEK_CXX='N'
153       ])
154
155    if test "x$HAVE_TWEEK_CXX" = "xY" ; then
156       JCCL_PATH_CXX([$jccl_version], [HAVE_TWEEK_CXX='Y'],
157          [AC_MSG_WARN([*** JCCL C++ API required for performance monitoring ***])
158           HAVE_TWEEK_CXX='N'
159          ])
160    fi
161 fi
162
163 if test "x$BUILD_JAVA" = "xY" ; then
164    JCCL_PATH_JAVA([$jccl_version], [test_tweek_java='Y'],
165       [AC_MSG_WARN([*** JCCL Java API required for VRJ Java plug-ins ***])
166        test_tweek_java='N'
167       ])
168
169    if test "x$test_tweek_java" = "xY" ; then
170       TWEEK_PATH_JAVA([$min_tweek_version], [HAVE_TWEEK_JAVA='Y'],
171          [AC_MSG_WARN([*** Tweek Java required for performance monitor JavaBean ***])
172           HAVE_TWEEK_JAVA='N'
173          ])
174    fi
175 fi
176
177 # -----------------------------------------------------------------------------
178 # Miscellaneous checks.
179 # -----------------------------------------------------------------------------
180 DPP_INSTALLER(vrjuggler, 0644, 0755, 0755)
181
182 # -----------------------------------------------------------------------------
183 # Do Makefile substitutions.
184 # -----------------------------------------------------------------------------
185 DATA_SUBDIR="$VRJ_DATA_SUBDIR"
186 PLUGIN_SUBDIR="$VRJ_PLUGIN_SUBDIR"
187
188 # Add these C++ options when compiling with G++.
189 #if test "x$GXX" = "xyes" ; then
190 #   CXXFLAGS="-fhonor-std $CXXFLAGS"
191 #fi
192
193 CXXFLAGS="$CXXFLAGS $CXX_VISIBILITY_FLAGS $VRJ_CXXFLAGS"
194 BASE_APP_LINK_FLAGS="$STDFLAGS $BASE_APP_LINK_FLAGS"
195 DEPEND_FLAGS="$VRJ_CXXFLAGS"
196
197 if test "x$PLATFORM" = "xIRIX" -a "x$USE_GCC" = "xno" ; then
198 #    CFLAGS="$CFLAGS -woff 1685,515,608,658,799,803,852,1048,1233,1499"
199 #    CXXFLAGS="$CXXFLAGS -woff 3322,1388 -w2"
200     CXXFLAGS="$CXXFLAGS -w2"
201     BASE_APP_LINK_FLAGS="$BASE_APP_LINK_FLAGS -J4 -all"
202 elif test "x$PLATFORM" = "xDarwin" ; then
203     changequote(<<, >>)
204     vpr_gcc_major=`echo $dpp_gcc_ver | sed -e 's/^\([0-9]*\)\..*/\1/'`
205     changequote([, ])
206
207     # GCC 4.0 in Darwin removed -fexport-coalesced.
208     if test $vpr_gcc_major -lt 4 ; then
209        CFLAGS_DYNLIB="$CFLAGS_DYNLIB -fexport-coalesced"
210        CXXFLAGS_DYNLIB="$CXXFLAGS_DYNLIB -fexport-coalesced"
211     fi
212
213     BASE_APP_LINK_FLAGS="$BASE_APP_LINK_FLAGS -Wl,-bind_at_load"
214 elif test "x$OS_TYPE" = "xWin32" -a "x$USE_GCC" != "xyes" ; then
215     vc_cflags='/QIfdiv /QI0f'
216     vc_cxxflags='/GR /GX /EHc /QIfdiv /QI0f'
217     CFLAGS="$CFLAGS /W3 $vc_cflags"
218     CXXFLAGS="$CXXFLAGS /W3 $vc_cxxflags"
219     BASE_APP_LINK_FLAGS="$BASE_APP_LINK_FLAGS /nologo /incremental:no"
220     DBG_FLAGS="$DBG_FLAGS /MDd"
221     OPT_FLAGS="$OPT_FLAGS /MD"
222 fi
223
224 # For makedepend(1) to work properly on HP-UX with aCC, we have to include
225 # these extra paths.
226 if test "x$PLATFORM" = "xHP" ; then
227     _aCC_ROOT="/opt/aCC"
228     DEPEND_EXTRAS="$DEPEND_EXTRAS -I${_aCC_ROOT} -I${_aCC_ROOT}/include -I${_aCC_ROOT}/include/iostream"
229 elif test "x$OS_TYPE" = "xWin32" ; then
230     DEPEND_EXTRAS="$DEPEND_EXTRAS -D__cplusplus"
231 fi
232
233 # $DSO_PLUGIN_DEPS must list all the libraries required to link a VRJ plug-in.
234 DSO_PLUGIN_DEPS="$VRJ_LIBS"
235 DSO_PLUGIN_PROF_DEPS="$VRJ_PROF_LIBS"
236 TWEEK_PLUGIN_DEPS="$TWEEK_LIBS"
237 TWEEK_PROF_PLUGIN_DEPS="$TWEEK_PROF_LIBS"
238
239 # Remove duplicated arguments from each of the following.  This can help speed
240 # up compile times, and it reduces the (perceived) complexity of the commands.
241 # These steps are performed here because no further additions are made to any
242 # of these variables after this point.
243 VJ_STRIP_DUPLICATE_ARGS(CXXFLAGS, [$CXXFLAGS])
244 VJ_STRIP_DUPLICATE_ARGS(DEPEND_FLAGS, [$DEPEND_FLAGS])
245 VJ_STRIP_DUPLICATE_ARGS_REVERSE([DSO_PLUGIN_DEPS], [$DSO_PLUGIN_DEPS])
246 VJ_STRIP_DUPLICATE_ARGS_REVERSE([DSO_PLUGIN_PROF_DEPS],
247                                 [$DSO_PLUGIN_PROF_DEPS])
248 VJ_BUILD_LIB_FILE_LIST([$DSO_PLUGIN_DEPS], [DSO_PLUGIN_DEP_FILES])
249 VJ_BUILD_LIB_FILE_LIST([$DSO_PLUGIN_PROF_DEPS], [DSO_PLUGIN_PROF_DEP_FILES])
250
251 DPP_SUBST
252
253 AC_SUBST(topdir)
254 AC_SUBST(UNIX_JUGGLERROOT_ABS)
255 AC_SUBST(PLUGIN_ROOT_ABS)
256 AC_SUBST(JUGGLERROOT_ABS)
257
258 AC_SUBST(DATA_SUBDIR)
259 AC_SUBST(PLUGIN_SUBDIR)
260
261 AC_SUBST(HAVE_TWEEK_CXX)
262 AC_SUBST(HAVE_TWEEK_JAVA)
263
264 AC_SUBST(ANT)
265 AC_SUBST(EXTRA_LDFLAGS)
266 AC_SUBST(RM_LN)
267
268 AC_SUBST(BUILD_JAVA)
269
270 AC_SUBST(DSO_PLUGIN_DEPS)
271 AC_SUBST(DSO_PLUGIN_DEP_FILES)
272 AC_SUBST(DSO_PLUGIN_PROF_DEPS)
273 AC_SUBST(DSO_PLUGIN_PROF_DEP_FILES)
274 AC_SUBST(TWEEK_PLUGIN_DEPS)
275 AC_SUBST(TWEEK_PLUGIN_PROF_DEPS)
276
277 # -----------------------------------------------------------------------------
278 # Final file generation step.
279 # -----------------------------------------------------------------------------
280 AC_CONFIG_FILES([
281    Makefile
282    Makefile.inc
283    common.defs.mk
284    make.defs.mk
285    plugin.defs.mk
286    corba_perf_mon/build.xml
287    corba_perf_mon/Makefile
288    ])
289
290 AC_OUTPUT
Note: See TracBrowser for help on using the browser.