[cgma-dev] r1206 - in cgm/trunk: . init itaps
kraftche at mcs.anl.gov
kraftche at mcs.anl.gov
Tue Jul 17 16:06:46 CDT 2007
Author: kraftche
Date: 2007-07-17 16:06:46 -0500 (Tue, 17 Jul 2007)
New Revision: 1206
Added:
cgm/trunk/init/
cgm/trunk/init/.libs/
cgm/trunk/init/InitCGMA.cpp
cgm/trunk/init/InitCGMA.hpp
cgm/trunk/init/Makefile
cgm/trunk/init/Makefile.am
Removed:
cgm/trunk/itaps/CGMA_ACIS.cc
cgm/trunk/itaps/CGMA_ACIS.h
Modified:
cgm/trunk/Makefile.am
cgm/trunk/cgm.make.in
cgm/trunk/configure.in
cgm/trunk/itaps/Makefile.am
cgm/trunk/itaps/iGeom_CGMA.cc
Log:
Add standard mechanism for initializing ACIS and other optional engines
- build as separate lib for use with either CGM or CUBIT
Change iGeom to use new mechanism for initializing ACIS
Modified: cgm/trunk/Makefile.am
===================================================================
--- cgm/trunk/Makefile.am 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/Makefile.am 2007-07-17 21:06:46 UTC (rev 1206)
@@ -1,5 +1,5 @@
AUTOMAKE_OPTIONS = foreign
-SUBDIRS = util geom itaps
+SUBDIRS = util geom init itaps
if build_ACIS
ACIS_EXAMPLE_TEST=cd cgm_apps/examples/driverc++; make check-TESTS
Modified: cgm/trunk/cgm.make.in
===================================================================
--- cgm/trunk/cgm.make.in 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/cgm.make.in 2007-07-17 21:06:46 UTC (rev 1206)
@@ -41,14 +41,33 @@
CGM_CFLAGS = @CFLAGS@
CGM_LDFLAGS = @LDFLAGS@
-CGM_INCLUDES = -I$(CGM_DIR)/util -I$(CGM_DIR)/geom -I$(CGM_DIR)/geom/ACIS $(CGM_PARALLEL_INCLUDE) -I$(CGM_INCLUDEDIR) ${ACIS_INCLUDES}
+CGM_INCLUDES = -I$(CGM_DIR)/util -I$(CGM_DIR)/init -I$(CGM_DIR)/geom -I$(CGM_DIR)/geom/ACIS $(CGM_PARALLEL_INCLUDE) -I$(CGM_INCLUDEDIR) ${ACIS_INCLUDES}
CGM_LIBS_LINK_INTERNAL = ${LDFLAGS} \
- -L$(CGM_DIR)/geom/virtual -L$(CGM_DIR)/geom/facetbool -L$(CGM_DIR)/geom/facet \
- -L$(CGM_DIR)/geom/Cholla -L$(CGM_DIR)/geom/ACIS -L$(CGM_DIR)/geom -L$(CGM_DIR)/util \
+ -L$(CGM_DIR)/geom/virtual/.libs \
+ -L$(CGM_DIR)/geom/facetbool/.libs \
+ -L$(CGM_DIR)/geom/facet/.libs \
+ -L$(CGM_DIR)/geom/Cholla/.libs \
+ -L$(CGM_DIR)/geom/ACIS/.libs \
+ -L$(CGM_DIR)/geom/.libs
+ -L$(CGM_DIR)/util/.libs \
+ -L$(CGM_DIR)/geom/virtual \
+ -L$(CGM_DIR)/geom/facetbool \
+ -L$(CGM_DIR)/geom/facet \
+ -L$(CGM_DIR)/geom/Cholla \
+ -L$(CGM_DIR)/geom/ACIS \
+ -L$(CGM_DIR)/geom
+ -L$(CGM_DIR)/util \
-L${ACIS_LIB_DIR} \
-L$(CGM_LIBDIR) \
- ${ACIS_LIBS} -lcubit_virtual -lcubit_facet -lcubit_facetbool -lcholla ${ACIS_LIBS} -lcubit_geom -lcubit_util \
+ ${ACIS_LIBS} \
+ -lcubit_virtual \
+ -lcubit_facet \
+ -lcubit_facetbool \
+ -lcholla \
+ ${ACIS_LIBS} \
+ -lcubit_geom \
+ -lcubit_util \
${CGM_PARALLEL_LIB}
CGM_LIBS_FILES_INTERNAL = \
@@ -65,6 +84,6 @@
CUBIT_LIBS = @CUBIT_LIBS@
CUBIT_FILE = @CUBIT_FILE@
-CGM_LIBS_LINK = @CGM_LIBS_LINK@
-CGM_LIBS_FILES = @CGM_LIBS_FILES@
+CGM_LIBS_LINK = @CGM_LIBS_LINK@ -L$(CGM_DIR)/init -L$(CGM_DIR)/init/.libs -lcubit_init
+CGM_LIBS_FILES = @CGM_LIBS_FILES@ $(CGM_LIBDIR)/libcubit_init.a
CGM_LIBS_LTFLAGS = @CGM_LIBS_LTFLAGS@
Modified: cgm/trunk/configure.in
===================================================================
--- cgm/trunk/configure.in 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/configure.in 2007-07-17 21:06:46 UTC (rev 1206)
@@ -250,6 +250,7 @@
geom/facetbool/Makefile
geom/parallel/Makefile
geom/virtual/Makefile
+ init/Makefile
cgm.make
itaps/Makefile
itaps/iGeom-Defs.inc
Added: cgm/trunk/init/InitCGMA.cpp
===================================================================
--- cgm/trunk/init/InitCGMA.cpp (rev 0)
+++ cgm/trunk/init/InitCGMA.cpp 2007-07-17 21:06:46 UTC (rev 1206)
@@ -0,0 +1,84 @@
+#include "InitCGMA.hpp"
+#include "CGMApp.hpp"
+#include "VirtualQueryEngine.hpp"
+#include "FacetQueryEngine.hpp"
+#include "FacetModifyEngine.hpp"
+
+#include <ctype.h>
+
+#ifdef CUBIT_CGM
+#include <new>
+
+class AcisModifyEngine
+{
+public:
+ AcisModifyEngine();
+ static AcisModifyEngine *instance_;
+};
+
+class AcisQueryEngine
+{
+public:
+ AcisQueryEngine();
+ static AcisQueryEngine *instance_;
+};
+
+class dummym
+{
+ char dummyvar[4096];
+};
+
+#elif defined(HAVE_ACIS)
+# include "AcisQueryEngine.hpp"
+# include "AcisModifyEngine.hpp"
+#endif
+
+
+static bool streq_nocase( const char* s, const char* t )
+{
+ for (; *s; ++s, ++t)
+ if (tolower(*s) != tolower(*t))
+ return false;
+ return !*t;
+}
+
+
+CubitStatus InitCGMA::initialize_cgma()
+{
+ CGMApp::instance()->startup( 0, NULL );
+ return CUBIT_SUCCESS;
+}
+
+
+CubitStatus InitCGMA::initialize_engine( const char* name )
+{
+ if (streq_nocase(name,"ACIS")) {
+#ifdef CUBIT_CGM
+ if (!AcisQueryEngine::instance_)
+ AcisQueryEngine::instance_ = new (reinterpret_cast<AcisQueryEngine*>(new dummym)) AcisQueryEngine;
+ if (!AcisModifyEngine::instance_)
+ AcisModifyEngine::instance_ = new (reinterpret_cast<AcisModifyEngine*>(new dummym)) AcisModifyEngine;
+#elif defined (HAVE_ACIS)
+ AcisQueryEngine::instance();
+ AcisModifyEngine::instance();
+#else
+ return CUBIT_FAILURE;
+#endif
+ }
+
+ else if (streq_nocase(name,"VIRTUAL") || streq_nocase(name,"vg")) {
+ VirtualQueryEngine::instance();
+ }
+
+ else if (streq_nocase(name,"facet")) {
+ FacetQueryEngine::instance();
+ FacetModifyEngine::instance();
+ }
+
+ else {
+ return CUBIT_FAILURE;
+ }
+
+ return CUBIT_SUCCESS;
+}
+
Added: cgm/trunk/init/InitCGMA.hpp
===================================================================
--- cgm/trunk/init/InitCGMA.hpp (rev 0)
+++ cgm/trunk/init/InitCGMA.hpp 2007-07-17 21:06:46 UTC (rev 1206)
@@ -0,0 +1,15 @@
+#ifndef INIT_CGMA_HPP
+#define INIT_CGMA_HPP
+
+#include "CubitDefines.h"
+
+class InitCGMA
+{
+public:
+
+ static CubitStatus initialize_cgma();
+
+ static CubitStatus initialize_engine( const char* name );
+};
+
+#endif
Added: cgm/trunk/init/Makefile
===================================================================
--- cgm/trunk/init/Makefile (rev 0)
+++ cgm/trunk/init/Makefile 2007-07-17 21:06:46 UTC (rev 1206)
@@ -0,0 +1,543 @@
+# Makefile.in generated by automake 1.9.6 from Makefile.am.
+# init/Makefile. Generated from Makefile.in by configure.
+
+# Copyright (C) 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002,
+# 2003, 2004, 2005 Free Software Foundation, Inc.
+# This Makefile.in is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY, to the extent permitted by law; without
+# even the implied warranty of MERCHANTABILITY or FITNESS FOR A
+# PARTICULAR PURPOSE.
+
+
+
+
+srcdir = .
+top_srcdir = ..
+
+pkgdatadir = $(datadir)/CGMA
+pkglibdir = $(libdir)/CGMA
+pkgincludedir = $(includedir)/CGMA
+top_builddir = ..
+am__cd = CDPATH="$${ZSH_VERSION+.}$(PATH_SEPARATOR)" && cd
+INSTALL = /usr/bin/install -c
+install_sh_DATA = $(install_sh) -c -m 644
+install_sh_PROGRAM = $(install_sh) -c
+install_sh_SCRIPT = $(install_sh) -c
+INSTALL_HEADER = $(INSTALL_DATA)
+transform = $(program_transform_name)
+NORMAL_INSTALL = :
+PRE_INSTALL = :
+POST_INSTALL = :
+NORMAL_UNINSTALL = :
+PRE_UNINSTALL = :
+POST_UNINSTALL = :
+build_triplet = x86_64-unknown-linux-gnu
+host_triplet = x86_64-unknown-linux-gnu
+target_triplet = x86_64-unknown-linux-gnu
+subdir = init
+DIST_COMMON = $(libcgma_init_la_include_HEADERS) $(srcdir)/Makefile.am \
+ $(srcdir)/Makefile.in
+ACLOCAL_M4 = $(top_srcdir)/aclocal.m4
+am__aclocal_m4_deps = $(top_srcdir)/configure.in
+am__configure_deps = $(am__aclocal_m4_deps) $(CONFIGURE_DEPENDENCIES) \
+ $(ACLOCAL_M4)
+mkinstalldirs = $(install_sh) -d
+CONFIG_HEADER = $(top_builddir)/config.h \
+ $(top_builddir)/itaps/iBase_FCDefs.h
+CONFIG_CLEAN_FILES =
+am__vpath_adj_setup = srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`;
+am__vpath_adj = case $$p in \
+ $(srcdir)/*) f=`echo "$$p" | sed "s|^$$srcdirstrip/||"`;; \
+ *) f=$$p;; \
+ esac;
+am__strip_dir = `echo $$p | sed -e 's|^.*/||'`;
+am__installdirs = "$(DESTDIR)$(libdir)" \
+ "$(DESTDIR)$(libcgma_init_la_includedir)"
+libLTLIBRARIES_INSTALL = $(INSTALL)
+LTLIBRARIES = $(lib_LTLIBRARIES)
+libcgma_init_la_LIBADD =
+am_libcgma_init_la_OBJECTS = InitCGMA.lo
+libcgma_init_la_OBJECTS = $(am_libcgma_init_la_OBJECTS)
+DEFAULT_INCLUDES = -I. -I$(srcdir) -I$(top_builddir) -I$(top_builddir)/itaps
+depcomp = $(SHELL) $(top_srcdir)/depcomp
+am__depfiles_maybe = depfiles
+CXXCOMPILE = $(CXX) $(DEFS) $(DEFAULT_INCLUDES) $(INCLUDES) \
+ $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
+LTCXXCOMPILE = $(LIBTOOL) --tag=CXX --mode=compile $(CXX) $(DEFS) \
+ $(DEFAULT_INCLUDES) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) \
+ $(AM_CXXFLAGS) $(CXXFLAGS)
+CXXLD = $(CXX)
+CXXLINK = $(LIBTOOL) --tag=CXX --mode=link $(CXXLD) $(AM_CXXFLAGS) \
+ $(CXXFLAGS) $(AM_LDFLAGS) $(LDFLAGS) -o $@
+SOURCES = $(libcgma_init_la_SOURCES)
+DIST_SOURCES = $(libcgma_init_la_SOURCES)
+libcgma_init_la_includeHEADERS_INSTALL = $(INSTALL_HEADER)
+HEADERS = $(libcgma_init_la_include_HEADERS)
+ETAGS = etags
+CTAGS = ctags
+DISTFILES = $(DIST_COMMON) $(DIST_SOURCES) $(TEXINFOS) $(EXTRA_DIST)
+ACIS_DEFS =
+ACIS_DIR = no
+ACIS_HEALER =
+ACIS_IGES_TRANSLATOR =
+ACIS_INCLUDES =
+ACIS_LIBS =
+ACIS_LIB_DIR = .
+ACIS_PLATFORM =
+ACIS_STEP_TRANSLATOR =
+ACIS_VERSION = 0
+ACLOCAL = ${SHELL} /home/jason/CGM/missing --run aclocal-1.9
+AMDEP_FALSE = #
+AMDEP_TRUE =
+AMTAR = ${SHELL} /home/jason/CGM/missing --run tar
+AR = ar
+AUTOCONF = ${SHELL} /home/jason/CGM/missing --run autoconf
+AUTOHEADER = ${SHELL} /home/jason/CGM/missing --run autoheader
+AUTOMAKE = ${SHELL} /home/jason/CGM/missing --run automake-1.9
+AWK = gawk
+BABEL_DIR =
+BUILD_CGM_FALSE =
+BUILD_CGM_TRUE = #
+CANT_USE_STD =
+CANT_USE_STD_IO =
+CC = cc
+CCDEPMODE = depmode=gcc3
+CFLAGS = -g
+CGM_ACIS_LIBS =
+CGM_LIBS_FILES = $(CUBIT_FILE)
+CGM_LIBS_LINK = $(CUBIT_LDFLAGS) $(CUBIT_LIBS)
+CGM_LIBS_LTFLAGS = $(CUBIT_LTFLAGS)
+CGM_PARALLEL_INCLUDE =
+CGM_PARALLEL_LIB =
+CGM_PARALLEL_LIB_FILE =
+CPP = cc -E
+CPPFLAGS =
+CUBIT_CGM = -DCUBIT_CGM
+CUBIT_FILE = /opt/cubit-10.1-amd64//bin/libcubiti19.so
+CUBIT_LDFLAGS = -L/opt/cubit-10.1-amd64//bin -L/opt/cubit-10.1-amd64//bin/lib -L/opt/cubit-10.1-amd64//libs
+CUBIT_LIBS = -lcubiti19
+CUBIT_LTFLAGS = -R/opt/cubit-10.1-amd64//bin -R/opt/cubit-10.1-amd64//bin/lib -R/opt/cubit-10.1-amd64//libs
+CXX = c++
+CXXCPP = c++ -E
+CXXDEPMODE = depmode=gcc3
+CXXFLAGS = -Wall -pipe -g
+CYGPATH_W = echo
+
+# Override default defines with the ones we want from the configure script
+DEFS = $(TEMPLATE_DEFS_INCLUDED) $(LITTLE_ENDIAN) $(HAVE_ACIS_DEF) $(CUBIT_CGM)
+DEPDIR = .deps
+ECHO = echo
+ECHO_C =
+ECHO_N = -n
+ECHO_T =
+EGREP = /bin/grep -E
+EXEEXT =
+F77 = g77
+FC = gfortran
+FCFLAGS = -g -O2
+FCLIBS = -L/usr/lib/gcc/x86_64-linux-gnu/4.1.2 -L/usr/lib/gcc/x86_64-linux-gnu/4.1.2/../../../../lib64 -L/lib/../lib64 -L/usr/lib/../lib64 -lgfortranbegin -lgfortran -lm
+FFLAGS = -g -O2
+GREP = /bin/grep
+HAVE_ACIS_DEF = -DHAVE_ACIS
+INCLUDE_TEMPLATE_DEFS_FALSE = #
+INCLUDE_TEMPLATE_DEFS_TRUE =
+INSTALL_DATA = ${INSTALL} -m 644
+INSTALL_PROGRAM = ${INSTALL}
+INSTALL_SCRIPT = ${INSTALL}
+INSTALL_STRIP_PROGRAM = ${SHELL} $(install_sh) -c -s
+LDFLAGS =
+LIBOBJS =
+LIBS = -lm
+LIBTOOL = $(SHELL) $(top_builddir)/libtool
+LITTLE_ENDIAN = -DLITTLE_ENDIAN=BYTE_ORDER
+LN_S = ln -s
+LTLIBOBJS =
+MAKEINFO = ${SHELL} /home/jason/CGM/missing --run makeinfo
+OBJEXT = o
+PACKAGE = CGMA
+PACKAGE_BUGREPORT =
+PACKAGE_NAME = CGMA
+PACKAGE_STRING = CGMA 10.2.2
+PACKAGE_TARNAME = cgma
+PACKAGE_VERSION = 10.2.2
+PATH_SEPARATOR = :
+RANLIB = ranlib
+SET_MAKE =
+SHELL = /bin/sh
+STRIP = strip
+TEMPLATE_DEFS_INCLUDED = -DTEMPLATE_DEFS_INCLUDED
+USE_BABEL = no
+USE_BABEL_FALSE =
+USE_BABEL_TRUE = #
+USE_MPI_FALSE =
+USE_MPI_TRUE = #
+VERSION = 10.2.2
+ac_ct_CC = cc
+ac_ct_CXX = c++
+ac_ct_F77 = g77
+ac_ct_FC = gfortran
+am__fastdepCC_FALSE = #
+am__fastdepCC_TRUE =
+am__fastdepCXX_FALSE = #
+am__fastdepCXX_TRUE =
+am__include = include
+am__leading_dot = .
+am__quote =
+am__tar = ${AMTAR} chof - "$$tardir"
+am__untar = ${AMTAR} xf -
+bindir = ${exec_prefix}/bin
+build = x86_64-unknown-linux-gnu
+build_ACIS_FALSE =
+build_ACIS_TRUE = #
+build_alias =
+build_cpu = x86_64
+build_os = linux-gnu
+build_parallel_FALSE =
+build_parallel_TRUE = #
+build_vendor = unknown
+datadir = ${datarootdir}
+datarootdir = ${prefix}/share
+docdir = ${datarootdir}/doc/${PACKAGE_TARNAME}
+dvidir = ${docdir}
+exec_prefix = ${prefix}
+host = x86_64-unknown-linux-gnu
+host_alias =
+host_cpu = x86_64
+host_os = linux-gnu
+host_vendor = unknown
+htmldir = ${docdir}
+includedir = ${prefix}/include
+infodir = ${datarootdir}/info
+install_sh = /home/jason/CGM/install-sh
+libdir = ${exec_prefix}/lib
+libexecdir = ${exec_prefix}/libexec
+localedir = ${datarootdir}/locale
+localstatedir = ${prefix}/var
+mandir = ${datarootdir}/man
+mkdir_p = mkdir -p --
+oldincludedir = /usr/include
+pdfdir = ${docdir}
+prefix = /usr/local
+program_transform_name = s,x,x,
+psdir = ${docdir}
+sbindir = ${exec_prefix}/sbin
+sharedstatedir = ${prefix}/com
+sysconfdir = ${prefix}/etc
+target = x86_64-unknown-linux-gnu
+target_alias =
+target_cpu = x86_64
+target_os = linux-gnu
+target_vendor = unknown
+
+# Don't require GNU-standard files (Changelog, README, etc.)
+AUTOMAKE_OPTIONS = foreign
+INCLUDES = -I$(top_srcdir)/geom \
+ -I$(top_srcdir)/util \
+ -I$(top_srcdir)/geom/ACIS \
+ -I$(top_srcdir)/geom/virtual \
+ -I$(top_srcdir)/geom/facet \
+ -I$(top_srcdir)/geom/cholla \
+ -I$(srcdir)
+
+lib_LTLIBRARIES = libcgma_init.la
+libcgma_init_la_includedir = $(includedir)
+libcgma_init_la_SOURCES = InitCGMA.cpp
+libcgma_init_la_include_HEADERS = InitCGMA.hpp
+all: all-am
+
+.SUFFIXES:
+.SUFFIXES: .cpp .lo .o .obj
+$(srcdir)/Makefile.in: $(srcdir)/Makefile.am $(am__configure_deps)
+ @for dep in $?; do \
+ case '$(am__configure_deps)' in \
+ *$$dep*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh \
+ && exit 0; \
+ exit 1;; \
+ esac; \
+ done; \
+ echo ' cd $(top_srcdir) && $(AUTOMAKE) --foreign init/Makefile'; \
+ cd $(top_srcdir) && \
+ $(AUTOMAKE) --foreign init/Makefile
+.PRECIOUS: Makefile
+Makefile: $(srcdir)/Makefile.in $(top_builddir)/config.status
+ @case '$?' in \
+ *config.status*) \
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh;; \
+ *) \
+ echo ' cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe)'; \
+ cd $(top_builddir) && $(SHELL) ./config.status $(subdir)/$@ $(am__depfiles_maybe);; \
+ esac;
+
+$(top_builddir)/config.status: $(top_srcdir)/configure $(CONFIG_STATUS_DEPENDENCIES)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+
+$(top_srcdir)/configure: $(am__configure_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+$(ACLOCAL_M4): $(am__aclocal_m4_deps)
+ cd $(top_builddir) && $(MAKE) $(AM_MAKEFLAGS) am--refresh
+install-libLTLIBRARIES: $(lib_LTLIBRARIES)
+ @$(NORMAL_INSTALL)
+ test -z "$(libdir)" || $(mkdir_p) "$(DESTDIR)$(libdir)"
+ @list='$(lib_LTLIBRARIES)'; for p in $$list; do \
+ if test -f $$p; then \
+ f=$(am__strip_dir) \
+ echo " $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) '$$p' '$(DESTDIR)$(libdir)/$$f'"; \
+ $(LIBTOOL) --mode=install $(libLTLIBRARIES_INSTALL) $(INSTALL_STRIP_FLAG) "$$p" "$(DESTDIR)$(libdir)/$$f"; \
+ else :; fi; \
+ done
+
+uninstall-libLTLIBRARIES:
+ @$(NORMAL_UNINSTALL)
+ @set -x; list='$(lib_LTLIBRARIES)'; for p in $$list; do \
+ p=$(am__strip_dir) \
+ echo " $(LIBTOOL) --mode=uninstall rm -f '$(DESTDIR)$(libdir)/$$p'"; \
+ $(LIBTOOL) --mode=uninstall rm -f "$(DESTDIR)$(libdir)/$$p"; \
+ done
+
+clean-libLTLIBRARIES:
+ -test -z "$(lib_LTLIBRARIES)" || rm -f $(lib_LTLIBRARIES)
+ @list='$(lib_LTLIBRARIES)'; for p in $$list; do \
+ dir="`echo $$p | sed -e 's|/[^/]*$$||'`"; \
+ test "$$dir" != "$$p" || dir=.; \
+ echo "rm -f \"$${dir}/so_locations\""; \
+ rm -f "$${dir}/so_locations"; \
+ done
+libcgma_init.la: $(libcgma_init_la_OBJECTS) $(libcgma_init_la_DEPENDENCIES)
+ $(CXXLINK) -rpath $(libdir) $(libcgma_init_la_LDFLAGS) $(libcgma_init_la_OBJECTS) $(libcgma_init_la_LIBADD) $(LIBS)
+
+mostlyclean-compile:
+ -rm -f *.$(OBJEXT)
+
+distclean-compile:
+ -rm -f *.tab.c
+
+include ./$(DEPDIR)/InitCGMA.Plo
+
+.cpp.o:
+ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \
+ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
+# source='$<' object='$@' libtool=no \
+# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
+# $(CXXCOMPILE) -c -o $@ $<
+
+.cpp.obj:
+ if $(CXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ `$(CYGPATH_W) '$<'`; \
+ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Po"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
+# source='$<' object='$@' libtool=no \
+# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
+# $(CXXCOMPILE) -c -o $@ `$(CYGPATH_W) '$<'`
+
+.cpp.lo:
+ if $(LTCXXCOMPILE) -MT $@ -MD -MP -MF "$(DEPDIR)/$*.Tpo" -c -o $@ $<; \
+ then mv -f "$(DEPDIR)/$*.Tpo" "$(DEPDIR)/$*.Plo"; else rm -f "$(DEPDIR)/$*.Tpo"; exit 1; fi
+# source='$<' object='$@' libtool=yes \
+# DEPDIR=$(DEPDIR) $(CXXDEPMODE) $(depcomp) \
+# $(LTCXXCOMPILE) -c -o $@ $<
+
+mostlyclean-libtool:
+ -rm -f *.lo
+
+clean-libtool:
+ -rm -rf .libs _libs
+
+distclean-libtool:
+ -rm -f libtool
+uninstall-info-am:
+install-libcgma_init_la_includeHEADERS: $(libcgma_init_la_include_HEADERS)
+ @$(NORMAL_INSTALL)
+ test -z "$(libcgma_init_la_includedir)" || $(mkdir_p) "$(DESTDIR)$(libcgma_init_la_includedir)"
+ @list='$(libcgma_init_la_include_HEADERS)'; for p in $$list; do \
+ if test -f "$$p"; then d=; else d="$(srcdir)/"; fi; \
+ f=$(am__strip_dir) \
+ echo " $(libcgma_init_la_includeHEADERS_INSTALL) '$$d$$p' '$(DESTDIR)$(libcgma_init_la_includedir)/$$f'"; \
+ $(libcgma_init_la_includeHEADERS_INSTALL) "$$d$$p" "$(DESTDIR)$(libcgma_init_la_includedir)/$$f"; \
+ done
+
+uninstall-libcgma_init_la_includeHEADERS:
+ @$(NORMAL_UNINSTALL)
+ @list='$(libcgma_init_la_include_HEADERS)'; for p in $$list; do \
+ f=$(am__strip_dir) \
+ echo " rm -f '$(DESTDIR)$(libcgma_init_la_includedir)/$$f'"; \
+ rm -f "$(DESTDIR)$(libcgma_init_la_includedir)/$$f"; \
+ done
+
+ID: $(HEADERS) $(SOURCES) $(LISP) $(TAGS_FILES)
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ mkid -fID $$unique
+tags: TAGS
+
+TAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ if test -z "$(ETAGS_ARGS)$$tags$$unique"; then :; else \
+ test -n "$$unique" || unique=$$empty_fix; \
+ $(ETAGS) $(ETAGSFLAGS) $(AM_ETAGSFLAGS) $(ETAGS_ARGS) \
+ $$tags $$unique; \
+ fi
+ctags: CTAGS
+CTAGS: $(HEADERS) $(SOURCES) $(TAGS_DEPENDENCIES) \
+ $(TAGS_FILES) $(LISP)
+ tags=; \
+ here=`pwd`; \
+ list='$(SOURCES) $(HEADERS) $(LISP) $(TAGS_FILES)'; \
+ unique=`for i in $$list; do \
+ if test -f "$$i"; then echo $$i; else echo $(srcdir)/$$i; fi; \
+ done | \
+ $(AWK) ' { files[$$0] = 1; } \
+ END { for (i in files) print i; }'`; \
+ test -z "$(CTAGS_ARGS)$$tags$$unique" \
+ || $(CTAGS) $(CTAGSFLAGS) $(AM_CTAGSFLAGS) $(CTAGS_ARGS) \
+ $$tags $$unique
+
+GTAGS:
+ here=`$(am__cd) $(top_builddir) && pwd` \
+ && cd $(top_srcdir) \
+ && gtags -i $(GTAGS_ARGS) $$here
+
+distclean-tags:
+ -rm -f TAGS ID GTAGS GRTAGS GSYMS GPATH tags
+
+distdir: $(DISTFILES)
+ @srcdirstrip=`echo "$(srcdir)" | sed 's|.|.|g'`; \
+ topsrcdirstrip=`echo "$(top_srcdir)" | sed 's|.|.|g'`; \
+ list='$(DISTFILES)'; for file in $$list; do \
+ case $$file in \
+ $(srcdir)/*) file=`echo "$$file" | sed "s|^$$srcdirstrip/||"`;; \
+ $(top_srcdir)/*) file=`echo "$$file" | sed "s|^$$topsrcdirstrip/|$(top_builddir)/|"`;; \
+ esac; \
+ if test -f $$file || test -d $$file; then d=.; else d=$(srcdir); fi; \
+ dir=`echo "$$file" | sed -e 's,/[^/]*$$,,'`; \
+ if test "$$dir" != "$$file" && test "$$dir" != "."; then \
+ dir="/$$dir"; \
+ $(mkdir_p) "$(distdir)$$dir"; \
+ else \
+ dir=''; \
+ fi; \
+ if test -d $$d/$$file; then \
+ if test -d $(srcdir)/$$file && test $$d != $(srcdir); then \
+ cp -pR $(srcdir)/$$file $(distdir)$$dir || exit 1; \
+ fi; \
+ cp -pR $$d/$$file $(distdir)$$dir || exit 1; \
+ else \
+ test -f $(distdir)/$$file \
+ || cp -p $$d/$$file $(distdir)/$$file \
+ || exit 1; \
+ fi; \
+ done
+check-am: all-am
+check: check-am
+all-am: Makefile $(LTLIBRARIES) $(HEADERS)
+installdirs:
+ for dir in "$(DESTDIR)$(libdir)" "$(DESTDIR)$(libcgma_init_la_includedir)"; do \
+ test -z "$$dir" || $(mkdir_p) "$$dir"; \
+ done
+install: install-am
+install-exec: install-exec-am
+install-data: install-data-am
+uninstall: uninstall-am
+
+install-am: all-am
+ @$(MAKE) $(AM_MAKEFLAGS) install-exec-am install-data-am
+
+installcheck: installcheck-am
+install-strip:
+ $(MAKE) $(AM_MAKEFLAGS) INSTALL_PROGRAM="$(INSTALL_STRIP_PROGRAM)" \
+ install_sh_PROGRAM="$(INSTALL_STRIP_PROGRAM)" INSTALL_STRIP_FLAG=-s \
+ `test -z '$(STRIP)' || \
+ echo "INSTALL_PROGRAM_ENV=STRIPPROG='$(STRIP)'"` install
+mostlyclean-generic:
+
+clean-generic:
+
+distclean-generic:
+ -test -z "$(CONFIG_CLEAN_FILES)" || rm -f $(CONFIG_CLEAN_FILES)
+
+maintainer-clean-generic:
+ @echo "This command is intended for maintainers to use"
+ @echo "it deletes files that may require special tools to rebuild."
+clean: clean-am
+
+clean-am: clean-generic clean-libLTLIBRARIES clean-libtool \
+ mostlyclean-am
+
+distclean: distclean-am
+ -rm -rf ./$(DEPDIR)
+ -rm -f Makefile
+distclean-am: clean-am distclean-compile distclean-generic \
+ distclean-libtool distclean-tags
+
+dvi: dvi-am
+
+dvi-am:
+
+html: html-am
+
+info: info-am
+
+info-am:
+
+install-data-am: install-libcgma_init_la_includeHEADERS
+
+install-exec-am: install-libLTLIBRARIES
+
+install-info: install-info-am
+
+install-man:
+
+installcheck-am:
+
+maintainer-clean: maintainer-clean-am
+ -rm -rf ./$(DEPDIR)
+ -rm -f Makefile
+maintainer-clean-am: distclean-am maintainer-clean-generic
+
+mostlyclean: mostlyclean-am
+
+mostlyclean-am: mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool
+
+pdf: pdf-am
+
+pdf-am:
+
+ps: ps-am
+
+ps-am:
+
+uninstall-am: uninstall-info-am uninstall-libLTLIBRARIES \
+ uninstall-libcgma_init_la_includeHEADERS
+
+.PHONY: CTAGS GTAGS all all-am check check-am clean clean-generic \
+ clean-libLTLIBRARIES clean-libtool ctags distclean \
+ distclean-compile distclean-generic distclean-libtool \
+ distclean-tags distdir dvi dvi-am html html-am info info-am \
+ install install-am install-data install-data-am install-exec \
+ install-exec-am install-info install-info-am \
+ install-libLTLIBRARIES install-libcgma_init_la_includeHEADERS \
+ install-man install-strip installcheck installcheck-am \
+ installdirs maintainer-clean maintainer-clean-generic \
+ mostlyclean mostlyclean-compile mostlyclean-generic \
+ mostlyclean-libtool pdf pdf-am ps ps-am tags uninstall \
+ uninstall-am uninstall-info-am uninstall-libLTLIBRARIES \
+ uninstall-libcgma_init_la_includeHEADERS
+
+# Tell versions [3.59,3.63) of GNU make to not export all variables.
+# Otherwise a system limit (for SysV at least) may be exceeded.
+.NOEXPORT:
Added: cgm/trunk/init/Makefile.am
===================================================================
--- cgm/trunk/init/Makefile.am (rev 0)
+++ cgm/trunk/init/Makefile.am 2007-07-17 21:06:46 UTC (rev 1206)
@@ -0,0 +1,20 @@
+# Don't require GNU-standard files (Changelog, README, etc.)
+AUTOMAKE_OPTIONS = foreign
+
+
+# Override default defines with the ones we want from the configure script
+DEFS = $(TEMPLATE_DEFS_INCLUDED) $(LITTLE_ENDIAN) $(HAVE_ACIS_DEF) $(CUBIT_CGM)
+INCLUDES = -I$(top_srcdir)/geom \
+ -I$(top_srcdir)/util \
+ -I$(top_srcdir)/geom/ACIS \
+ -I$(top_srcdir)/geom/virtual \
+ -I$(top_srcdir)/geom/facet \
+ -I$(top_srcdir)/geom/cholla \
+ -I$(srcdir)
+
+lib_LTLIBRARIES = libcgma_init.la
+libcgma_init_la_includedir = $(includedir)
+libcgma_init_la_SOURCES = InitCGMA.cpp
+libcgma_init_la_include_HEADERS = InitCGMA.hpp
+
+
Deleted: cgm/trunk/itaps/CGMA_ACIS.cc
===================================================================
--- cgm/trunk/itaps/CGMA_ACIS.cc 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/itaps/CGMA_ACIS.cc 2007-07-17 21:06:46 UTC (rev 1206)
@@ -1,35 +0,0 @@
-#include "CGMA_ACIS.h"
-#include <new>
-
-class AcisModifyEngine
-{
-public:
- AcisModifyEngine();
- static AcisModifyEngine *instance_;
-};
-
-
-class AcisQueryEngine
-{
-public:
- AcisQueryEngine();
- static AcisQueryEngine *instance_;
-};
-
-
-class dummym
-{
- char dummyvar[4096];
-};
-
-
-int CGMA_initialize_ACIS()
-{
- if (!AcisQueryEngine::instance_)
- AcisQueryEngine::instance_ = new (reinterpret_cast<AcisQueryEngine*>(new dummym)) AcisQueryEngine;
- if (!AcisModifyEngine::instance_)
- AcisModifyEngine::instance_ = new (reinterpret_cast<AcisQueryEngine*>(new dummym)) AcisModifyEngine;
- return 0;
-}
-
-
Deleted: cgm/trunk/itaps/CGMA_ACIS.h
===================================================================
--- cgm/trunk/itaps/CGMA_ACIS.h 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/itaps/CGMA_ACIS.h 2007-07-17 21:06:46 UTC (rev 1206)
@@ -1,14 +0,0 @@
-#ifndef CGMA_ACIS_H
-#define CGMA_ACIS_H
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-int CGMA_initialize_ACIS();
-
-#ifdef __cplusplus
-} // extern "C"
-#endif
-
-#endif
Modified: cgm/trunk/itaps/Makefile.am
===================================================================
--- cgm/trunk/itaps/Makefile.am 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/itaps/Makefile.am 2007-07-17 21:06:46 UTC (rev 1206)
@@ -25,27 +25,24 @@
$(top_builddir)/geom/libcubit_geom.la \
$(top_builddir)/util/libcubit_util.la
TEST_XLDFLAGS = -R$(ACIS_LIB_DIR)
- CGM_ACIS_SRCS =
else
TEST_XLDFLAGS = $(CUBIT_LDFLAGS) $(CUBIT_LTFLAGS)
TEST_XLIBS = $(CUBIT_LIBS)
-# If not building CGM, then have Cubit library w/ ACIS support
- CGM_ACIS_SRCS = CGMA_ACIS.cc
endif
if build_ACIS
- ACIS_SRCS = CGMA_ACIS.cc
ACIS_CGM_INCLUDES = -I$(top_srcdir)/geom/ACIS
else
- ACIS_SRCS =
ACIS_CGM_INCLUDES =
endif
libiGeom_la_includedir = $(includedir)
+libiGeom_la_libadd = $(top_builddir)/init/libcgma_init.la $(TEST_XLIBS)
+
INCLUDES = -I$(top_srcdir)/util \
-I$(top_srcdir)/geom \
- $(ACIS_CGM_INCLUDES ) \
+ -I$(top_srcdir)/init \
-I.
libiGeom_la_SOURCES = \
@@ -53,10 +50,7 @@
CATag.cpp \
iGeom_CGMA.cc \
iGeomError.cc \
- iGeomError.h \
- CGMA_ACIS.h \
- $(ACIS_SRCS) \
- $(CGM_ACIS_SRCS)
+ iGeomError.h
libiGeom_la_include_HEADERS = \
iBase.h \
Modified: cgm/trunk/itaps/iGeom_CGMA.cc
===================================================================
--- cgm/trunk/itaps/iGeom_CGMA.cc 2007-07-17 17:55:11 UTC (rev 1205)
+++ cgm/trunk/itaps/iGeom_CGMA.cc 2007-07-17 21:06:46 UTC (rev 1206)
@@ -21,6 +21,7 @@
* 2007-6-15
*/
#include "iGeom.h"
+#include "InitCGMA.hpp"
#include <iostream>
#include <math.h>
@@ -30,11 +31,6 @@
# include "config.h"
#endif
-#ifdef HAVE_ACIS
-# include "CGMA_ACIS.h"
-#endif
-
-
const bool debug = false;
#define RETURN(a) do {iGeom_setLastError((*err = a)); return; } while(false)
@@ -241,12 +237,8 @@
ERROR(iBase_NOT_SUPPORTED, "No options for iGeom factory have been implemented.");
}
- CGMApp::instance()->startup( 0, NULL );
-
- // assuem for now that we want ACIS
-#ifdef HAVE_ACIS
- CGMA_initialize_ACIS();
-#endif
+ InitCGMA::initialize_cgma();
+ InitCGMA::initialize_engine("ACIS");
// sometimes can't have following, depending on CGM version
// CGMApp::instance()->attrib_manager()->silent_flag(true);
More information about the cgma-dev
mailing list