~ubuntu-branches/ubuntu/hoary/scilab/hoary

« back to all changes in this revision

Viewing changes to examples/mex-examples/mex-with-objects/Makefile

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2005-01-09 22:58:21 UTC
  • mfrom: (1.1.1 upstream)
  • Revision ID: james.westby@ubuntu.com-20050109225821-473xr8vhgugxxx5j
Tags: 3.0-12
changed configure.in to build scilab's own malloc.o, closes: #255869

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
SCIDIR=../../..
2
 
 
3
 
include $(SCIDIR)/Makefile.incl
4
 
 
5
 
CFLAGS = $(CC_OPTIONS) $(CC_PICFLAGS) -I$(SCIDIR)/routines
6
 
FFLAGS = $(FC_OPTIONS) $(FC_PICFLAGS) -I$(SCIDIR)/routines
7
 
 
8
 
################# List of source mexfiles ######################
9
 
CMEXSOURCES = mexfunction1.c mexfunction2.c mexfunction3.c \
10
 
        mexfunction4.c mexfunction5.c mexfunction6.c \
11
 
        mexfunction7.c mexfunction8.c mexfunction9.c \
12
 
        mexfunction10.c mexfunction11.c  mexfunction12.c  \
13
 
        mexfunction13.c 
14
 
 
15
 
FORTRANMEXSOURCES = 
16
 
 
17
 
################# List of associated Scilab functions  ##########
18
 
#               (= by default the name of the mexfunction)      #
19
 
FCTS = $(CMEXSOURCES:.c=) $(FORTRANMEXSOURCES:.f=)
20
 
 
21
 
################## List of routines used by the mexfiles ########
22
 
OTHERCSOURCES = 
23
 
OTHERFORTRANSOURCES = 
24
 
 
25
 
################## Name of startup file (default = "startup.sce") #
26
 
 
27
 
STARTUP = startup
28
 
################## Name of gateway file (default = "generic_gateway.c #
29
 
 
30
 
GENERIC = generic
31
 
########## Do not edit below this line #############
32
 
 
33
 
MEXOBJS = $(CMEXSOURCES:.c=.o) $(FORTRANMEXSOURCES:.f=.o)
34
 
 
35
 
OTHEROBJS = $(OTHERCSOURCES:.c=.o) $(OTHERFORTRANSOURCES:.f=.o)
36
 
 
37
 
OTHERSOURCES = $(OTHERCSOURCES) $(OTHERFORTRANSOURCES)
38
 
 
39
 
MEXSOURCES = $(CMEXSOURCES) $(FORTRANMEXSOURCES)
40
 
 
41
 
OBJS = $(MEXOBJS) $(OTHEROBJS) $(GENERIC)_gateway.o
42
 
 
43
 
all     :: all_nomes message
44
 
 
45
 
all_nomes : $(GENERIC)_gateway.c $(OBJS) $(STARTUP).sce 
46
 
 
47
 
clean   ::
48
 
        $(RM) *.o so_locations $(STARTUP).sce $(GENERIC)_gateway.c
49
 
 
50
 
distclean ::
51
 
        $(RM) *.o so_locations $(STARTUP).sce $(GENERIC)_gateway.c
52
 
 
53
 
$(GENERIC)_gateway.c $(STARTUP).sce : Makefile 
54
 
        @echo "-- Generating the C function $(GENERIC)_gateway.c";
55
 
        @echo "-- ... and the Scilab script $(STARTUP).sce";
56
 
        @echo $(FCTS) > tmp_arg1;
57
 
        @echo $(OTHEROBJS) > tmp_arg2;
58
 
        @echo $(MEXSOURCES) > tmp_arg3; 
59
 
        @echo $(STARTUP) $(GENERIC) > tmp_arg4;
60
 
        @$(SCIDIR)/macros/Gengatsce Xtmp_arg1 Xtmp_arg2 Xtmp_arg3 Xtmp_arg4;
61
 
        @$(RM) tmp_arg1 tmp_arg2 tmp_arg3 tmp_arg4; 
62
 
 
63
 
message:
64
 
        @echo "------------------------------------------";
65
 
        @echo "To load $(FCTS)";
66
 
        @echo "        functions, at Scilab prompt, enter:";
67
 
        @echo "-->exec $(STARTUP).sce";
68
 
        @echo "------------------------------------------";
69
 
 
70
 
rmold:
71
 
        $(RM) $(GENERIC)_gateway.c $(STARTUP).sce
72
 
 
73
 
tests   :  mexobjs.dia
74
 
 
75
 
mexobjs.dia     : mexobjs.tst $(OBJS)  $(STARTUP).sce all_nomes 
76
 
        @$(SCIDIR)/util/scidem $(SCIDIR) mexobjs.tst mexobjs.dia
77