Salome HOME
Update copyright
[modules/smesh.git] / src / SMESH_SWIG_WITHIHM / Makefile.am
1 # Copyright (C) 2007-2011  CEA/DEN, EDF R&D, OPEN CASCADE
2 #
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.
7 #
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.
12 #
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
16 #
17 # See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 #
19
20 # SMESH SMESHGUI : GUI for SMESH component
21 # File   : Makefile.am
22 # Author : Alexander BORODIN, Open CASCADE S.A.S.
23 #
24 include $(top_srcdir)/adm_local/unix/make_common_starter.am
25
26 # ===============================================================
27 # Swig targets
28 # ===============================================================
29 # (cf. http://www.geocities.com/foetsch/python/swig_linux.htm)
30 #
31 # Step 1: build the wrapping source files with swig
32 #
33 # libSALOME_LifeCycleCORBA.i -- swig --> swig_wrap.cpp
34 #                                        libSALOME_Swig.py
35 #
36 # Step 2: build the dynamic library from cpp built source files and
37 #         dependant libraries.
38 #
39 # swig_wrap.cpp -- gcc --> swig_wrap.o    |-- link --> _libSMESH_Swig.la
40 #                          +              |
41 #                          dependant libs |
42 #
43 # The file libSMESH_Swig.py will be installed to the
44 # <prefix>/bin/salome directory.
45 # The library _libSMESH_Swig.so will be installed to the 
46 # <prefix>/lib/python<version>/site-package/salome directory.
47 #
48
49 SWIG_FLAGS    = @SWIG_FLAGS@ -I$(srcdir) -I$(srcdir)/../SMESHGUI
50 SWIG_SOURCES  = libSMESH_Swig.i
51
52 salomeinclude_HEADERS = $(SWIG_SOURCES) libSMESH_Swig.h
53
54 # Libraries targets
55 lib_LTLIBRARIES                  = _libSMESH_Swig.la
56 _libSMESH_Swig_la_SOURCES        = $(SWIG_SOURCES) libSMESH_Swig.h libSMESH_Swig.cxx
57 nodist__libSMESH_Swig_la_SOURCES = swig_wrap.cpp
58
59 _libSMESH_Swig_la_CPPFLAGS =    \
60         $(QT_INCLUDES)          \
61         $(PYTHON_INCLUDES)      \
62         $(CAS_CPPFLAGS)         \
63         $(VTK_INCLUDES)         \
64         $(OGL_INCLUDES)         \
65         $(KERNEL_CXXFLAGS)      \
66         $(GUI_CXXFLAGS)         \
67         $(MED_CXXFLAGS)         \
68         $(GEOM_CXXFLAGS)        \
69         $(CORBA_CXXFLAGS)       \
70         $(CORBA_INCLUDES)       \
71         $(BOOST_CPPFLAGS)       \
72         -I$(srcdir)             \
73         -I$(srcdir)/../SMESHGUI \
74         -I$(top_builddir)/idl
75
76 _libSMESH_Swig_la_LDFLAGS  = -module
77 _libSMESH_Swig_la_LIBADD   = ../SMESHGUI/libSMESH.la                    \
78         $(KERNEL_LDFLAGS) -lSalomeGenericObj -lSALOMELocalTrace         \
79         $(GUI_LDFLAGS) -lCAM -lsuit -lqtx -lSalomeApp -lstd -lEvent     \
80         $(PYTHON_LIBS) $(QT_MT_LIBS)
81
82 swig_wrap.cpp : $(SWIG_SOURCES)
83         $(SWIG) $(SWIG_FLAGS) -o $@ $<
84
85 libSMESH_Swig.py: swig_wrap.cpp
86
87 CLEANFILES = swig_wrap.cpp libSMESH_Swig.py
88
89 #
90 # ===============================================================
91 # Files to be installed
92 # ===============================================================
93 #
94
95 # Scripts to be installed (distributed)
96 dist_salomescript_DATA =
97
98 # Scripts to be installed (non-distributed)
99 nodist_salomescript_DATA = libSMESH_Swig.py