1 # Copyright (C) 2007-2012 CEA/DEN, EDF R&D, OPEN CASCADE
3 # This library is free software; you can redistribute it and/or
4 # modify it under the terms of the GNU Lesser General Public
5 # License as published by the Free Software Foundation; either
6 # version 2.1 of the License.
8 # This library is distributed in the hope that it will be useful,
9 # but WITHOUT ANY WARRANTY; without even the implied warranty of
10 # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
11 # Lesser General Public License for more details.
13 # You should have received a copy of the GNU Lesser General Public
14 # License along with this library; if not, write to the Free Software
15 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
20 include $(top_srcdir)/adm_local/unix/make_common_starter.am
22 # ===============================================================
24 # ===============================================================
25 # (cf. http://www.geocities.com/foetsch/python/swig_linux.htm)
27 # Step 1: build the wrapping source files with swig
29 # libSALOME_LifeCycleCORBA.i -- swig --> swig_wrap.cpp
32 # Step 2: build the dynamic library from cpp built source files and
33 # dependant libraries.
35 # swig_wrap.cpp -- gcc --> swig_wrap.o |-- link --> _libGEOM_Swig.la
39 # The files libGEOM_Swig.py and _libGEOM_Swig.so will be installed to the
40 # <prefix>/lib/python<version>/site-package/salome directory.
43 SWIG_FLAGS = @SWIG_FLAGS@ -I$(srcdir) -I$(srcdir)/../GEOMGUI
44 SWIG_SOURCES = libGEOM_Swig.i
46 salomeinclude_HEADERS = $(SWIG_SOURCES) libGEOM_Swig.h
48 salomepython_PYTHON = libGEOM_Swig.py
49 salomepyexec_LTLIBRARIES = _libGEOM_Swig.la
51 _libGEOM_Swig_la_SOURCES = $(SWIG_SOURCES) libGEOM_Swig.h libGEOM_Swig.cxx
52 nodist__libGEOM_Swig_la_SOURCES = swig_wrap.cpp
54 _libGEOM_Swig_la_CPPFLAGS = \
64 -I$(srcdir)/../GEOMClient \
65 -I$(srcdir)/../OBJECT \
66 -I$(srcdir)/../GEOMGUI \
67 -I$(srcdir)/../GEOMToolsGUI \
70 _libGEOM_Swig_la_LDFLAGS = -module
71 _libGEOM_Swig_la_LIBADD = \
72 ../GEOMGUI/libGEOM.la \
73 ../GEOMToolsGUI/libGEOMToolsGUI.la \
76 swig_wrap.cpp : $(SWIG_SOURCES)
77 $(SWIG) $(SWIG_FLAGS) -o $@ $<
79 libGEOM_Swig.py: swig_wrap.cpp
81 CLEANFILES = swig_wrap.cpp libGEOM_Swig.py