Salome HOME
Update copyright information
[modules/superv.git] / idl / Makefile.in
1 #  Copyright (C) 2007-2008  CEA/DEN, EDF R&D, OPEN CASCADE
2 #
3 #  Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4 #  CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5 #
6 #  This library is free software; you can redistribute it and/or
7 #  modify it under the terms of the GNU Lesser General Public
8 #  License as published by the Free Software Foundation; either
9 #  version 2.1 of the License.
10 #
11 #  This library is distributed in the hope that it will be useful,
12 #  but WITHOUT ANY WARRANTY; without even the implied warranty of
13 #  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
14 #  Lesser General Public License for more details.
15 #
16 #  You should have received a copy of the GNU Lesser General Public
17 #  License along with this library; if not, write to the Free Software
18 #  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
19 #
20 #  See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21 #
22 #  File   : Makefile.in
23 #  Module : idl
24 #
25 top_srcdir=@top_srcdir@
26 top_builddir=..
27 srcdir=@srcdir@
28 VPATH=.:${KERNEL_ROOT_DIR}/idl/salome
29
30 @COMMENCE@
31
32 IDL_FILES = \
33   SUPERV.idl \
34   ObjRef_omniORB4.idl
35
36 PY_CLIENT_IDL = $(IDL_FILES)
37
38 # we copy all idl file in $(top_builddir)/idl
39 inc: $(top_builddir)/idl/salome $(IDL_FILES:%=$(top_builddir)/idl/salome/%)
40
41 $(top_builddir)/idl/salome:
42         mkdir $@
43
44 $(IDL_FILES:%=$(top_builddir)/idl/salome/%):$(IDL_FILES:%=$(top_srcdir)/idl/%)
45 #       $(CP) $< $@
46         cp -f $^ $(top_builddir)/idl/salome
47
48
49 lib: pyidl
50
51 PYTHON_BUILD_SITE=$(top_builddir)/lib@LIB_LOCATION_SUFFIX@/python$(PYTHON_VERSION)/site-packages/@PACKAGE@
52
53 pyidl: $(PYTHON_BUILD_SITE) $(IDL_FILES:%.idl=$(PYTHON_BUILD_SITE)/%_idl.py)
54
55 $(PYTHON_BUILD_SITE):
56         $(INSTALL) -d  $@
57
58 $(PYTHON_BUILD_SITE)/%_idl.py: $(top_builddir)/idl/salome/%.idl
59         $(OMNIORB_IDL) $(OMNIORB_IDLPYFLAGS) -C$(PYTHON_BUILD_SITE) $<
60
61
62 # install python client (generated from idl file
63 install: install-pyidl install-idl
64
65 # create directory $(idldir) and copy idl files into it
66 install-idl: $(IDL_FILES:%=$(top_builddir)/idl/salome/%)
67         $(INSTALL) -d  $(idldir)
68         $(INSTALL_DATA) $^ $(idldir)
69
70
71 install-pyidl: $(IDL_FILES:%=$(top_builddir)/idl/salome/%)
72         $(INSTALL) -d  $(PYTHON_SITE_INSTALL)
73         @for file in $^ dummy; do \
74           if [ $$file != "dummy" ]; then \
75             $(OMNIORB_IDL) $(OMNIORB_IDLPYFLAGS) -C$(PYTHON_SITE_INSTALL) $$file ; \
76           fi ; \
77         done ;
78
79 #@ CONCLUDE @
80
81 cleandep:
82         -$(RM) .dep*
83
84 distclean:
85         -$(RM) *.py
86         -$(RM) $(IDL_FILES:%=$(top_builddir)/idl/salome/%)
87         -$(RM) Makefile
88