]> SALOME platform Git repositories - modules/gui.git/blob - src/SALOME_PYQT/SalomePyQt/Makefile.am
Salome HOME
Join modifications from BR_Dev_For_4_0 tag V4_1_1.
[modules/gui.git] / src / SALOME_PYQT / SalomePyQt / Makefile.am
1 # Copyright (C) 2005  OPEN CASCADE, CEA/DEN, EDF R&D, PRINCIPIA R&D
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 #  File   : Makefile.in
20 #  Author : Nicolas REJNERI
21 #  Module : SALOME
22
23 include $(top_srcdir)/adm_local/unix/make_common_starter.am
24
25 # Sip flags
26 SIP_FLAGS = -t WS_X11 -t $(QT_VERS) $(PYQT_SIPFLAGS) -s ".cc" -c . -I $(PYQT_SIPS)
27
28 # Sip common sources
29 SIP_SRC = sipSalomePyQtSalomePyQt.cc \
30           sipSalomePyQtSALOME_Selection.cc \
31           sipSalomePyQtQtxAction.cc
32
33 # Sip version-specific sources
34 if IS_SIP_V4
35 SIP_SRC  += sipSalomePyQtcmodule.cc
36 else !IS_SIP_V4
37 SIP_SRC  += SalomePyQtcmodule.cc
38 endif
39
40 # Sip/moc sources and Sip definition files
41 if IS_SIP_V4
42 if IS_SIP_NEW
43 MOC_SRC   = 
44 MOC_H     = 
45 SIP_FILES = SalomePyQt_v4.sip
46 else !IS_SIP_NEW
47 MOC_SRC   = sipSalomePyQtcmodule_moc.cxx
48 MOC_H     = sipSalomePyQtcmodule.h
49 SIP_FILES = SalomePyQt_v4.sip
50 endif
51 else !IS_SIP_V4
52 SIP_FILES = SalomePyQt.sip
53 if IS_SIP_NEW
54 MOC_SRC   = SalomePyQtcmodule_moc.cxx
55 MOC_H     = SalomePyQtcmodule.h
56 else !IS_SIP_NEW
57 MOC_SRC   = sipSalomePyQtProxySalomePyQt_moc.cxx
58 MOC_H     = sipSalomePyQtProxySalomePyQt.h
59 endif
60 endif
61
62 EXTRA_DIST+= SalomePyQt.sip SalomePyQt_v4.sip
63
64 # Libraries targets
65 MOC_FILES= SalomePyQt_moc.cxx
66
67 COMMON_CPP_FLAGS=$(QT_INCLUDES) $(SIP_INCLUDES) $(PYTHON_INCLUDES) \
68         $(CAS_CPPFLAGS) $(VTK_INCLUDES) $(OGL_INCLUDES) $(BOOST_CPPFLAGS) \
69         -DHAVE_CONFIG_H @KERNEL_CXXFLAGS@ -I$(top_builddir)/salomeadn/unix \
70         -I$(top_builddir)/idl \
71         -I$(srcdir)/../../SUIT -I$(srcdir)/../../CAM -I$(srcdir)/../../STD \
72         -I$(srcdir)/../../Qtx -I$(srcdir)/../../SalomeApp -I$(srcdir)/../../Event \
73         -I$(srcdir)/../../SalomeSession -I$(srcdir)/../../LogWindow \
74         -I$(srcdir)/../../VTKViewer -I$(srcdir)/../../TOOLSGUI \
75         -I$(srcdir)/../SALOME_PYQT_GUI -I$(srcdir)/../../PyInterp \
76         -I$(srcdir)/../../LightApp -I$(srcdir)/../../ObjBrowser \
77         -I$(srcdir)/../../OBJECT \
78         -I$(top_builddir)/salome_adm/unix @CORBA_CXXFLAGS@ @CORBA_INCLUDES@
79
80 COMMON_LIBS=$(PYTHON_LIBS) $(SIP_LIBS) $(PYQT_LIBS) $(VTK_LIBS) \
81         $(OGL_LIBS) ../../SUIT/libsuit.la ../../CAM/libCAM.la ../../STD/libstd.la \
82         ../../Qtx/libqtx.la ../../SalomeApp/libSalomeApp.la ../../Event/libEvent.la \
83         ../../Session/libSalomeSession.la ../../LogWindow/libLogWindow.la \
84         ../../VTKViewer/libVTKViewer.la ../../TOOLSGUI/libToolsGUI.la \
85         ../SALOME_PYQT_GUI/libSalomePyQtGUI.la
86
87 if IS_SIP_V4
88
89 lib_LTLIBRARIES = libSalomePyQt.la
90 dist_libSalomePyQt_la_SOURCES= SalomePyQt.cxx
91 nodist_libSalomePyQt_la_SOURCES= $(MOC_FILES) $(SIP_SRC) $(MOC_SRC) 
92 libSalomePyQt_la_CPPFLAGS = $(COMMON_CPP_FLAGS)
93 libSalomePyQt_la_LIBADD = $(COMMON_LIBS)
94
95 else !IS_SIP_V4
96
97 lib_LTLIBRARIES = libSalomePyQtcmodule.la
98 dist_libSalomePyQtcmodule_la_SOURCES= SalomePyQt.cxx
99 nodist_libSalomePyQtcmodule_la_SOURCES= $(MOC_FILES) $(SIP_SRC) $(MOC_SRC)
100 libSalomePyQtcmodule_la_CPPFLAGS = $(MY_CPP_FLAGS)
101 libSalomePyQtcmodule_la_LIBADD = $(COMMON_LIBS)
102
103 endif
104
105 if IS_SIP_V4
106 else
107 nodist_sharedpkgpython_PYTHON= SalomePyQt.py
108 endif
109
110 # Custom build step: generate C++ wrapping according to $(SIP_FILES)
111 $(SIP_SRC): $(SIP_FILES)
112         $(SIP) $(SIP_FLAGS) $<
113
114 $(MOC_H): $(SIP_FILES)
115         $(SIP) $(SIP_FLAGS) $<
116
117 if IS_SIP_V4
118 install-exec-hook: $(libdir)/SalomePyQt.so
119 $(libdir)/SalomePyQt.so:
120         (cd $(libdir); ln -s libSalomePyQt.so SalomePyQt.so;)
121 else !IS_SIP_V4
122 install-exec-hook: $(libdir)/SalomePyQtcmodule.so
123 $(libdir)/SalomePyQt.so:
124         (cd $(libdir); ln -sf libSalomePyQtcmodule.so SalomePyQt.so;)
125 endif
126
127 $(SIP_SRC): $(MOC_SRC)