Fixes to resolve several build issues

This commit is contained in:
sborho 2003-07-16 21:05:10 +00:00
parent c113cec8ab
commit a11f545941
11 changed files with 97 additions and 86 deletions

View file

@ -1,3 +1,6 @@
July 16, 2003 steve@borho.org
Updated autoconf files to fix several build issues.
January 03, 2003 msripada@evl.uic.edu
Fixed a bug in Object.cpp at void Object::do_broadphase of a
type mismatch bug.

View file

@ -1 +1,3 @@
SUBDIRS = libmoto libbroad libsolid sample doc
EXTRA_DIST = include

View file

@ -78,6 +78,14 @@ The auxiliary C++ classes in `include/3D' may be used for performing 3D
transformations. The classes have all their code inlined, so you do not
need to link a library in order to use them.
If you've checked out a fresh CVS sandbox, the following steps are
required to generate a proper 'configure' file.
aclocal
automake -a
autoconf
autoheader
Documentation

View file

@ -1,41 +0,0 @@
# Process this file with autoconf to produce a configure script.
AC_INIT(FreeSOLID, 0.1, gino@dtecta.com)
AM_INIT_AUTOMAKE(FreeSOLID, 0.1)
AM_CONFIG_HEADER([include/config.h])
# Checks for programs.
AC_PROG_CXX
AC_PROG_CC
AC_PROG_INSTALL
AC_PROG_RANLIB
AC_PROG_LIBTOOL
# Checks for libraries.
AC_CHECK_HEADERS(qhull/qhull_a.h)
AC_CHECK_LIB(qhull, main, s_have_qhull=yes)
if test "X${s_have_qhull}" = Xyes; then
QHULL_LIBS="-lqhull"
else
QHULL_LIBS=""
fi
AC_SUBST([QHULL_LIBS])
# Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS([float.h limits.h stddef.h stdlib.h string.h])
# Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_C_INLINE
# Checks for library functions.
AC_CHECK_FUNCS([sqrt])
AC_CONFIG_FILES([Makefile
doc/Makefile
libmoto/Makefile
libbroad/Makefile
libsolid/Makefile
sample/Makefile])
AC_OUTPUT

46
freesolid/configure.in Normal file
View file

@ -0,0 +1,46 @@
dnl Process this file with autoconf to produce a configure script.
AC_INIT(sample/sample.cpp)
AC_CANONICAL_SYSTEM
PACKAGE=FreeSOLID
VERSION=2.1.1
AM_INIT_AUTOMAKE($PACKAGE, $VERSION)
AM_CONFIG_HEADER(include/config.h)
dnl Checks for programs.
AC_PROG_CXX
AC_PROG_CC
AC_PROG_CPP
AC_PROG_INSTALL
AC_PROG_RANLIB
AC_PROG_LIBTOOL
dnl Checks for libraries.
dnl Replace `main' with a function in -lm:
AC_CHECK_LIB(m, main)
dnl Replace `main' with a function in -lqhull:
AC_CHECK_LIB(qhull, main, s_have_qhull=yes)
if test "X${s_have_qhull}" = Xyes; then
QHULL_LIBS="-lqhull"
else
QHULL_LIBS=""
fi
AC_SUBST(QHULL_LIBS)
dnl Checks for header files.
AC_HEADER_STDC
AC_CHECK_HEADERS(qhull/qhull_a.h)
AC_CHECK_HEADERS(limits.h)
dnl Checks for typedefs, structures, and compiler characteristics.
AC_C_CONST
AC_C_INLINE
dnl Checks for library functions.
AC_CHECK_FUNCS(sqrt)
AC_CHECK_FUNCS(fabs)
AC_OUTPUT(doc/Makefile sample/Makefile Makefile libbroad/Makefile libmoto/Makefile libsolid/Makefile)

View file

@ -29,9 +29,15 @@
#include <math.h>
#include <stdlib.h>
#include "config.h"
typedef double Scalar;
#if HAVE_FABS
/* If Scalar is changed to a float, use fabsf instead */
#define abs(dbl) fabs(dbl)
#endif
const Scalar DEGS_PER_RAD = 57.29577951308232286465;
const Scalar RADS_PER_DEG = 0.01745329251994329547;
const Scalar TWO_PI = 6.28318530717958623200;
@ -39,7 +45,6 @@ const Scalar EPSILON = 1.0e-10;
const Scalar EPSILON2 = 1.0e-20;
const Scalar SOLID_INFINITY = 1.0e50;
inline Scalar rnd() { return (Scalar(rand()) + 0.5) / (Scalar(RAND_MAX) + 1); }
inline Scalar sabs(Scalar x) { return x < 0 ? -x : x; }
inline int sgn(Scalar x) { return x < 0 ? -1 : x > 0 ? 1 : 0; }

View file

@ -1,41 +0,0 @@
/* include/config.h.in. Generated automatically from configure.ac by autoheader. */
/* Define if you have the <dlfcn.h> header file. */
#undef HAVE_DLFCN_H
/* Define if you have the <float.h> header file. */
#undef HAVE_FLOAT_H
/* Define if you have the `qhull' library (-lqhull). */
#undef HAVE_QHULL_QHULL_A_H
/* Define if you have the <limits.h> header file. */
#undef HAVE_LIMITS_H
/* Define if you have the `sqrt' function. */
#undef HAVE_SQRT
/* Define if you have the <stddef.h> header file. */
#undef HAVE_STDDEF_H
/* Define if you have the <stdlib.h> header file. */
#undef HAVE_STDLIB_H
/* Define if you have the <string.h> header file. */
#undef HAVE_STRING_H
/* Name of package */
#undef PACKAGE
/* Define if you have the ANSI C header files. */
#undef STDC_HEADERS
/* Version number of package */
#undef VERSION
/* Define to empty if `const' does not conform to ANSI C. */
#undef const
/* Define as `__inline' if that's what the C compiler calls it, or to nothing
if it is not supported. */
#undef inline

View file

@ -1 +0,0 @@
timestamp

View file

@ -1 +0,0 @@
timestamp

View file

@ -13,3 +13,5 @@ pkginclude_HEADERS = \
BP_Endpoint.h \
BP_Proxy.h \
BP_Scene.h
EXTRA_DIST = broad.dsp

View file

@ -1,4 +1,5 @@
lib_LTLIBRARIES = libmoto.la
libmoto_la_SOURCES = \
GEN_random.cpp \
MT_Matrix3x3.cpp \
@ -9,7 +10,35 @@ libmoto_la_SOURCES = \
MT_Vector2.cpp \
MT_Vector3.cpp \
MT_Vector4.cpp
CPPFLAGS = -DGEN_INLINED
pkginclude_HEADERS = \
GEN_List.h \
GEN_MinMax.h \
GEN_Optimize.h \
GEN_random.h \
GEN_Stream.h \
MT_Matrix3x3.h \
MT_Point2.h \
MT_Point3.h \
MT_Point.h \
MT_Quaternion.h \
MT_Scalar.h \
MT_Transform.h \
MT_Tuple2.h \
MT_Tuple3.h \
MT_Tuple4.h \
MT_Vector2.h \
MT_Vector3.h \
MT_Vector4.h
EXTRA_DIST = \
moto.dsp \
MT_Matrix3x3.inl \
MT_Point2.inl \
MT_Point3.inl \
MT_Quaternion.inl \
MT_Vector2.inl \
MT_Vector3.inl \
MT_Vector4.inl