Salome HOME
Join modifications from branch OCC_debug_for_3_2_0b1
[samples/component.git] / Makefile.in
1 #  Copyright (C) 2005  CEA/DEN, EDF 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/
18 #
19 # -* Makefile *- 
20 #
21 # Author : C. Caremoli
22 # Date : 10/10/2003
23 # $Header$
24 #
25
26 # source path
27 top_srcdir=@top_srcdir@
28 top_builddir=.
29 srcdir=@srcdir@
30 VPATH=.:@srcdir@:@top_srcdir@/bin:@top_srcdir@/resources:./bin:@top_srcdir@/idl
31
32 @COMMENCE@
33
34 SUBDIRS = idl src adm_local
35
36 RESOURCES_FILES = \
37         COMPONENTCatalog.xml SalomeApp.xml
38
39 BIN_SCRIPT= VERSION
40
41 # copy header files in common directory
42 ifeq ($(HAVE_SSTREAM),yes)
43   include_list=include/salome/SALOMEconfig.h
44 else
45   include_list=include/salome/SALOMEconfig.h include/salome/sstream
46 endif
47
48 inc: idl $(include_list)
49
50 include/salome/SALOMEconfig.h: salome_adm/unix/SALOMEconfig.ref
51         -$(RM) $@
52         $(LN_S) ../../$< $@
53
54 # test if SALOMEconfig.h has changed (contents)
55 salome_adm/unix/SALOMEconfig.ref: salome_adm/unix/SALOMEconfig.h
56         @if ! [ -a $@ ]; then \
57           cp -p -f $< $@;        \
58         fi;                   \
59         if ! cmp $< $@; then  \
60           cp -p -f $< $@;        \
61         fi;                   \
62
63 include/salome/sstream: salome_adm/unix/sstream
64         -$(RM) $@
65         $(LN_S) ../../$< $@
66
67 depend: depend_idl
68
69 depend_idl:
70         (cd idl ; $(MAKE) $@) || exit 1
71
72 # doc is already build : if you want to had documents, go manually to doc and run 'make doc'
73 #doc:
74 #       (cd doc && $(MAKE) $@) || exit 1
75
76 install-end:
77 # finish libtool install
78 #       @$(LT) --mode=finish $(libdir)
79
80 install-include: $(include_list)
81         $(INSTALL) -d  $(includedir)
82         @for f in X $(include_list); do                         \
83            if test $$f != X; then                               \
84              ($(INSTALL_DATA) -p $$f $(includedir)/. || exit 1);        \
85            fi;                                                  \
86         done
87
88 # install script in $(bindir) :
89 install-bin: $(BIN_SCRIPT)
90         $(INSTALL) -d  $(bindir)
91         $(INSTALL_PROGRAM) $^ $(bindir)
92
93 uninstall: uninstall-idl
94
95 uninstall-idl:
96         $(RM) $(idldir)/*.idl
97
98 distclean: distclean-other
99
100 distclean-other:
101         -$(RM) salome_adm/unix/*~ salome_adm/unix/*% salome_adm/unix/*.bak salome_adm/unix/*.new salome_adm/unix/*.old
102         -$(RM) salome_adm/unix/make_* 
103         -$(RM) salome_adm/unix/depend salome_adm/unix/SALOMEconfig.h 
104         -$(RM) config.cache config.log config.status 
105
106 @MODULE@
107
108 install: install-bin install-include install-end
109