+dnl Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+dnl CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+dnl
+dnl This library is free software; you can redistribute it and/or
+dnl modify it under the terms of the GNU Lesser General Public
+dnl License as published by the Free Software Foundation; either
+dnl version 2.1 of the License.
+dnl
+dnl This library is distributed in the hope that it will be useful,
+dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
+dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+dnl Lesser General Public License for more details.
+dnl
+dnl You should have received a copy of the GNU Lesser General Public
+dnl License along with this library; if not, write to the Free Software
+dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+dnl
+dnl See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+dnl
+dnl
+dnl
AC_DEFUN([CHECK_CAS],[
AC_REQUIRE([AC_PROG_CXX])dnl
AC_REQUIRE([AC_PROG_CXXCPP])dnl
+dnl Copyright (C) 2003 CEA/DEN, EDF R&D
AC_DEFUN([CHECK_PYQT],[
AC_REQUIRE([CHECK_PYTHON])dnl
AC_CHECKING(for pyqt)
-pyqt_ok=no
+pyqt_ok=yes
PYTHON_SITE_PACKPYQT=$PYTHON_PREFIX/lib/python$PYTHON_VERSION/site-packages
AC_CHECK_FILES($PYTHON_SITE_PACKPYQT/qt.py $PYTHON_SITE_PACKPYQT/libqtcmodule.so,pyqt_ok=yes,pyqt_ok=no)
[ --with-pyuic=EXEC pyuic executable ],
[PYUIC="$withval"
AC_MSG_RESULT("select $withval as pyqt executable")
- ], [
- AC_PATH_PROG(PYUIC, pyuic)
])
if test "x$PYUIC" = "x"
+dnl Copyright (C) 2003 CEA/DEN, EDF R&D
AC_DEFUN([CHECK_SIP],[
AC_REQUIRE([CHECK_PYTHON])dnl
+dnl Copyright (C) 2003 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+dnl CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+dnl
+dnl This library is free software; you can redistribute it and/or
+dnl modify it under the terms of the GNU Lesser General Public
+dnl License as published by the Free Software Foundation; either
+dnl version 2.1 of the License.
+dnl
+dnl This library is distributed in the hope that it will be useful,
+dnl but WITHOUT ANY WARRANTY; without even the implied warranty of
+dnl MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+dnl Lesser General Public License for more details.
+dnl
+dnl You should have received a copy of the GNU Lesser General Public
+dnl License along with this library; if not, write to the Free Software
+dnl Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+dnl
+dnl See http://www.opencascade.org/SALOME/ or email : webmaster.salome@opencascade.org
+dnl
+dnl
+dnl
+
AC_DEFUN([CHECK_VTK],[
AC_REQUIRE([AC_PROG_CC])dnl
AC_REQUIRE([AC_PROG_CXX])dnl
LOCAL_INCLUDES="$OGL_INCLUDES"
-LOCAL_LIBS="-lVTKCommon -lVTKGraphics -lVTKImaging -lVTKContrib $OGL_LIBS -L$x_libraries -lX11 -lXt"
-TRY_LINK_LIBS="-lVTKCommon $OGL_LIBS -L$x_libraries -lX11 -lXt"
+LOCAL_LIBS="-lvtkCommon -lvtkGraphics -lvtkImaging -lvtkPatented -lvtkFiltering -lvtkIO -lvtkRendering -lvtkHybrid $OGL_LIBS -L$x_libraries -lX11 -lXt"
+TRY_LINK_LIBS="-lvtkCommon $OGL_LIBS -L$x_libraries -lX11 -lXt"
if test -z $VTKHOME
then
AC_MSG_WARN(undefined VTKHOME variable which specify where vtk was compiled)
else
- LOCAL_INCLUDES="-I$VTKHOME/common -I$VTKHOME/imaging -I$VTKHOME/graphics -I$VTKHOME/contrib $LOCAL_INCLUDES"
- LOCAL_LIBS="-L$VTKHOME/lib -L$VTKHOME/common -L$VTKHOME/graphics -L$VTKHOME/imaging -L$VTKHOME/contrib $LOCAL_LIBS"
- TRY_LINK_LIBS="-L$VTKHOME/lib -L$VTKHOME/common $TRY_LINK_LIBS"
+ LOCAL_INCLUDES="-I$VTKHOME/include/vtk $LOCAL_INCLUDES"
+ LOCAL_LIBS="-L$VTKHOME/lib/vtk $LOCAL_LIBS"
+ TRY_LINK_LIBS="-L$VTKHOME/lib/vtk $TRY_LINK_LIBS"
fi
dnl vtk headers
CPPFLAGS_old="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $LOCAL_INCLUDES -Wno-deprecated"
-AC_CHECK_HEADER(vtk.h,vtk_ok="yes",vtk_ok="no")
+AC_CHECK_HEADER(vtkPlane.h,vtk_ok="yes",vtk_ok="no")
-CPPFLAGS="$CPPFLAGS_old"
+ CPPFLAGS="$CPPFLAGS_old"
-if test "x$vtk_ok" = "xyes"
-then
- VTK_INCLUDES="$LOCAL_INCLUDES"
+ if test "x$vtk_ok" = "xyes"
+ then
+ VTK_INCLUDES="$LOCAL_INCLUDES"
-dnl vtk libraries
+ dnl vtk libraries
- AC_MSG_CHECKING(linking VTK library)
+ AC_MSG_CHECKING(linking VTK library)
LIBS_old="$LIBS"
# LIBS="$LIBS $TRY_LINK_LIBS"
CPPFLAGS_old="$CPPFLAGS"
CPPFLAGS="$CPPFLAGS $VTK_INCLUDES -Wno-deprecated"
-dnl VTKPY_MODULES="$VTKHOME/python"
+ dnl VTKPY_MODULES="$VTKHOME/python"
- AC_CACHE_VAL(salome_cv_lib_vtk,[
- AC_TRY_LINK(
-#include <vtk.h>
+ AC_CACHE_VAL(salome_cv_lib_vtk,[
+ AC_TRY_LINK(
+#include "vtkPlane.h"
, vtkPlane *p = vtkPlane::New();,
eval "salome_cv_lib_vtk=yes",eval "salome_cv_lib_vtk=no")
])
AC_CACHE_SAVE
])dnl
+
+
# common directories to put headerfiles
-inc_builddir=$(top_builddir)/include/salome
+inc_builddir=$(top_builddir)/include
@SET_MAKE@
SHELL=/bin/sh
OCC_MODELER_LIBS=@CAS_MODELER@
OCC_DATAEXCHANGE_LIBS=@CAS_DATAEXCHANGE@
OCC_LIBS=@CAS_LDFLAGS@
-
+CAS_KERNEL=@CAS_KERNEL@
+CAS_OCAF=@CAS_OCAF@
+CAS_VIEWER=@CAS_VIEWER@
+CAS_MODELER=@CAS_MODELER@
+CAS_DATAEXCHANGE=@CAS_DATAEXCHANGE@
# MPICH
MPICH_INCLUDES=@MPICH_INCLUDES@
OMNIORB_IDL = @OMNIORB_IDL@
OMNIORB_IDLCXXFLAGS = @OMNIORB_IDLCXXFLAGS@
-OMNIORB_IDLPYFLAGS = @OMNIORB_IDLPYFLAGS@ -I$(top_builddir)/idl
+OMNIORB_IDLPYFLAGS = @OMNIORB_IDLPYFLAGS@ -I$(top_srcdir)/share/salome/idl
OMNIORB_IDL_CLN_H = @OMNIORB_IDL_CLN_H@
OMNIORB_IDL_CLN_CXX = @OMNIORB_IDL_CLN_CXX@
## Installation points
prefix=@prefix@
exec_prefix=@exec_prefix@
-bindir=@bindir@/salome
-libdir=@libdir@/salome
+bindir=@bindir@
+libdir=@libdir@
# warning : if user give this path in configure we could have salome/salome :-(
includedir=@includedir@/salome
datadir=@datadir@/salome
sharedpydir=@libdir@/python$(PYTHON_VERSION)/site-packages/salome/shared_modules
incmakedir=${prefix}/salome_adm/unix
-docdir=$(datadir)/doc
+docdir=@exec_prefix@/doc
#
# begin of package rules
# all libtool obj file in library
LIB_OBJ = $(LIB_OBJ_CXX) $(LIB_OBJ_CC) $(LIB_OBJ_C) $(LIB_CLIENT_OBJ:%.o=%.lo) $(LIB_SERVER_OBJ:%.o=%.lo) $(LIB_SWIG_OBJ) $(LIB_OBJ_F)
-# LIB_BUILD = $(LIB:%.la=$(top_builddir)/lib/salome/%.la)
-LIB_BUILD = $(patsubst %.la, $(top_builddir)/lib/salome/%.la, $(filter %.la, $(LIB)))
-LIB_BUILD_A = $(patsubst %.a, $(top_builddir)/lib/salome/%.a, $(filter %.a, $(LIB)))
+# LIB_BUILD = $(LIB:%.la=$(top_builddir)/lib/%.la)
+LIB_BUILD = $(patsubst %.la, $(top_builddir)/lib/%.la, $(filter %.la, $(LIB)))
+LIB_BUILD_A = $(patsubst %.a, $(top_builddir)/lib/%.a, $(filter %.a, $(LIB)))
ifneq ($(findstring cmodule.la,$(filter %.la, $(LIB))),)
LIB_SWIG = $(patsubst %cmodule.la,%.so, $(filter %.la, $(LIB)))
lib: $(LIB_BUILD) $(LIB_CLIENT_PY)
# we don't build static library !
-$(LIB_BUILD): $(top_builddir)/lib/salome/%.la: %.la
+$(LIB_BUILD): $(top_builddir)/lib/%.la: %.la
-$(RM) $@
-$(RM) $(patsubst %.la, %.so, $@)
-$(RM) $(patsubst %.la, %.a, $@)
- ln -s $(CURDIR)/$< $@ || true
- ln -s $(patsubst %.la, %.so, $(CURDIR)/.libs/$<) \
+ ln -sf $(CURDIR)/$< $@ || true
+ ln -sf $(patsubst %.la, %.so, $(CURDIR)/.libs/$<) \
$(patsubst %.la, %.so, $@) || true
- ln -s $(patsubst %.la, %.so, $(CURDIR)/.libs/$<).0 \
+ ln -sf $(patsubst %.la, %.so, $(CURDIR)/.libs/$<).0 \
$(patsubst %.la, %.so, $@).0 || true
if ! test -z $(LIB_SWIG) ; then \
- ln -s $(patsubst %.la,%.so, $(CURDIR)/.libs/$<) $(top_builddir)/lib/salome/_$(LIB_SWIG) || true;\
+ ln -sf $(patsubst %.la,%.so, $(CURDIR)/.libs/$<) $(top_builddir)/lib/_$(LIB_SWIG) || true;\
fi;
-$(LIB_BUILD_A): $(top_builddir)/lib/salome/%.a: %.a
+$(LIB_BUILD_A): $(top_builddir)/lib/%.a: %.a
-$(RM) $@
- ln -s $(CURDIR)/$< $@ || true
+ ln -sf $(CURDIR)/$< $@ || true
$(LIB): $(LIB_OBJ)
@$(LT) --mode=link $(CXX) -rpath $(libdir) -o $@ $(CXXFLAGS) $(LIB_OBJ) $(LDFLAGS) $(LIBS)
# all obj file in bin target
BIN_OBJ = $(BIN_OBJ_CC) $(BIN_OBJ_CXX) $(BIN_OBJ_C) $(BIN_CLIENT_OBJ) $(BIN_SERVER_OBJ)
-bin: $(BIN:%=$(top_builddir)/bin/salome/%) $(BIN) $(LIB) pyscripts sharedpyscripts
+bin: $(BIN:%=$(top_builddir)/bin/%) $(BIN) $(LIB) pyscripts sharedpyscripts
BIN_LIB=$(LIB:lib%.la=-l%)
-$(BIN:%=$(top_builddir)/bin/salome/%) $(TEST_PROGS:%=$(top_builddir)/bin/salome/%): $(top_builddir)/bin/salome/%: %
+$(BIN:%=$(top_builddir)/bin/%) $(TEST_PROGS:%=$(top_builddir)/bin/%): $(top_builddir)/bin/%: %
-$(RM) $@
- ln -s $(CURDIR)/$< $@
+ ln -sf $(CURDIR)/$< $@
$(BIN) $(TEST_PROGS): %: %.lo $(BIN_OBJ)
$(CXX) $(CXXFLAGS) -o $@ $^ $(BIN_LIB) $(LDFLAGS) $(LIBS)
-# copy python scripts in $(top_builddir)/bin/salome
+# copy python scripts in $(top_builddir)/bin
#
-DEST_PYSCRIPTS = $(EXPORT_PYSCRIPTS:%=$(top_builddir)/bin/salome/%)
+DEST_PYSCRIPTS = $(EXPORT_PYSCRIPTS:%=$(top_builddir)/bin/%)
pyscripts: $(DEST_PYSCRIPTS)
-$(DEST_PYSCRIPTS): $(top_builddir)/bin/salome/%: %
+$(DEST_PYSCRIPTS): $(top_builddir)/bin/%: %
cp -f $< $@
# copy pyqt files in $(PYTHON_SHARED_SITE)
tests: test
-test: $(LIB) $(TEST_PROGS:%=$(top_builddir)/bin/salome/%)
+test: $(LIB) $(TEST_PROGS:%=$(top_builddir)/bin/%)
# copy header file in $(inc_builddir)
fi; \
done
@if ! test -z $(LIB_SWIG) ; then \
- (cd $(libdir); ln -s $(patsubst %.so, %cmodule.so, $(LIB_SWIG)) _$(LIB_SWIG) || true); \
+ (cd $(libdir); ln -sf $(patsubst %.so, %cmodule.so, $(LIB_SWIG)) _$(LIB_SWIG) || true); \
fi;
@for f in X $(BIN); do \
if test $$f != X; then \
-$(RM) $(LIB) $(TEST_PROGS) $(BIN) $(CLEAN)
-$(RM) TAGS *~ *# core *.core
-$(RM) -r .libs
- -$(RM) $(top_builddir)/lib/salome/$(LIB)
- -$(RM) $(patsubst %,$(top_builddir)/bin/salome/%, $(BIN))
- -$(RM) $(patsubst %.la, %.so, $(top_builddir)/lib/salome/$(LIB))
- -$(RM) $(patsubst %.la, %.a, $(top_builddir)/lib/salome/$(LIB))
+ -$(RM) $(top_builddir)/lib/$(LIB)
+ -$(RM) $(patsubst %,$(top_builddir)/bin/%, $(BIN))
+ -$(RM) $(patsubst %.la, %.so, $(top_builddir)/lib/$(LIB))
+ -$(RM) $(patsubst %.la, %.a, $(top_builddir)/lib/$(LIB))
# remove idl generated files (sources)
-$(RM) $(LIB_CLIENT_SRC) $(LIB_SERVER_SRC) $(BIN_CLIENT_SRC) $(BIN_SERVER_SRC)
# remove idl generated files (headers)
$(SWIG) $(SWIG_FLAGS) -o $@ $<
$(top_builddir)/share/salome/resources/%.qm: %.po
- if test -e ${KERNEL_ROOT_DIR}/bin/salome/msg2qm ; then \
- ${KERNEL_ROOT_DIR}/bin/salome/msg2qm $< $@ ; \
- else \
- $(top_builddir)/bin/salome/msg2qm $< $@ ; \
- fi
+ $(top_builddir)/bin/msg2qm $< $@
#------------------------------------------------------------------------------
# The following section of this makefile contains dependencies between the