2
|
1 #--------------------------------------------------------------------------
|
|
2 # RPELTP makefile for the MSDOS port of the gcc compiler (DJGPP)
|
|
3 #--------------------------------------------------------------------------
|
|
4 # Original Copyright message:
|
|
5 # Copyright 1992 by Jutta Degener and Carsten Bormann, Technische
|
|
6 # Universitaet Berlin. See the accompanying file "COPYRIGHT" for
|
|
7 # details. THERE IS ABSOLUTELY NO WARRANTY FOR THIS SOFTWARE.
|
|
8 #
|
|
9 # File adapted by simao@cpqd.ansp.br for the UGST distribution.
|
|
10 #--------------------------------------------------------------------------
|
|
11 #
|
|
12
|
|
13 # Machine dependent flags you must configure to port
|
|
14 ######### Define SASR if >> is a signed arithmetic shift (-1 >> 1 == -1)
|
|
15 SASR = -DSASR
|
|
16
|
|
17 ######### MUST Define USE_FLOAT_MUL for bit exact performance to GSM Spec.
|
|
18 #MULHACK = -DUSE_FLOAT_MUL
|
|
19
|
|
20 # Choose a compiler. The code works both with ANSI and K&R-C.
|
|
21 # Use -DNeedFunctionPrototypes to compile with, -UNeedFunctionPrototypes to
|
|
22 # compile without, function prototypes in the header files.
|
|
23 #
|
|
24 # You can use the -DSTUPID_COMPILER to circumvent some compilers'
|
|
25 # static limits regarding the number of subexpressions in a statement.
|
|
26
|
|
27 CC = gcc
|
|
28 CCFLAGS = -c -O2 -DNeedFunctionPrototypes=1 -I../utl
|
|
29
|
|
30 LD = $(CC)
|
|
31 # LDFLAGS =
|
|
32 # LDLIB =
|
|
33
|
|
34
|
|
35 #--------------------------------------------------------------------------
|
|
36 #
|
|
37 # You shouldn't have to configure below this line if you're porting.
|
|
38 #
|
|
39 #--------------------------------------------------------------------------
|
|
40
|
|
41
|
|
42 # Tools
|
|
43 RM=rm -f
|
|
44
|
|
45 # Local Directories
|
|
46
|
|
47 ROOT = .. ### <---
|
|
48 ADDTST = $(ROOT)/add-test
|
|
49 TST = $(ROOT)/tst
|
|
50 MAN = $(ROOT)/man
|
|
51 BIN = $(ROOT)/bin
|
|
52 ###SRC = $(ROOT)/ugst ### <---
|
|
53 SRC = .
|
|
54 LIB = $(ROOT)/lib
|
|
55 TLS = $(ROOT)/tls
|
|
56 ###INC = $(ROOT)/inc
|
|
57 INC = c:\gcc\include
|
|
58
|
|
59 # Flags
|
|
60
|
|
61 DEBUG = -DNDEBUG
|
|
62 ######### Remove -DNDEBUG to enable assertions.
|
|
63
|
|
64 CFLAGS = $(CCFLAGS) $(SASR) $(DEBUG) $(MULHACK) $(FAST) $(CCINC) -I$(INC)
|
|
65 ######### It's $(CC) $(CFLAGS)
|
|
66
|
|
67 LFLAGS = $(LDFLAGS) $(LDINC)
|
|
68 ######### It's $(LD) $(LFLAGS)
|
|
69
|
|
70
|
|
71 #--------------------------------------------------------------------------
|
|
72 # Headers
|
|
73 HEADERS = proto.h unproto.h config.h private.h gsm.h rpeltp.h
|
|
74
|
|
75 #--------------------------------------------------------------------------
|
|
76 # Sources
|
|
77 GSM_SOURCES = add.c code.c debug.c decode.c long_ter.c lpc.c \
|
|
78 preproce.c rpe.c gsm_dest.c gsm_deco.c gsm_enco.c \
|
|
79 gsm_expl.c gsm_impl.c gsm_crea.c gsm_prin.c gsm_opti.c \
|
|
80 rpeltp.c short_te.c table.c
|
|
81
|
|
82 DEMO_SOURCES = rpedemo.c ../g711/g711.c
|
|
83
|
|
84 SOURCES = $(GSM_SOURCES) $(DEMO_SOURCES)
|
|
85
|
|
86
|
|
87 #--------------------------------------------------------------------------
|
|
88 # Object files
|
|
89 GSM_OBJECTS = add.o code.o debug.o decode.o long_ter.o lpc.o \
|
|
90 preproce.o rpe.o gsm_dest.o gsm_deco.o gsm_enco.o \
|
|
91 gsm_expl.o gsm_impl.o gsm_crea.o gsm_prin.o gsm_opti.o \
|
|
92 rpeltp.o short_te.o table.o
|
|
93
|
|
94 DEMO_OBJECTS = rpedemo.o g711.o
|
|
95
|
|
96 OBJECTS = $(GSM_OBJECTS) $(DEMO_OBJECTS)
|
|
97
|
|
98 # ------------------------------------------------
|
|
99 # Implicit rules
|
|
100 # ------------------------------------------------
|
|
101 .c.o:
|
|
102 $(CC) $(CFLAGS) $<
|
|
103
|
|
104 # ------------------------------------------------
|
|
105 # Generic rules
|
|
106 # ------------------------------------------------
|
|
107 all:: rpedemo
|
|
108
|
|
109 clean:
|
|
110 $(RM) $(OBJECTS)
|
|
111
|
|
112 cleantest:
|
|
113 echo No test file processing available in this directory
|
|
114
|
|
115 veryclean: clean
|
|
116 $(RM) rpedemo
|
|
117
|
|
118 # ------------------------------------------------
|
|
119 # Specific rules
|
|
120 # ------------------------------------------------
|
|
121 g711.o: ../g711/g711.c
|
|
122 $(CC) $(CFLAGS) -I../g711 ../g711/g711.c
|
|
123
|
|
124 rpedemo.o: rpedemo.c ../g711/g711.h
|
|
125 $(CC) $(CFLAGS) -I../g711 rpedemo.c
|
|
126
|
|
127 rpedemo: $(OBJECTS)
|
|
128 $(CC) -o rpedemo $(OBJECTS)
|
|
129
|
|
130 # ------------------------------------------------
|
|
131 # Run add < add_test.dta to make sure the
|
|
132 # basic arithmetic functions work as intended.
|
|
133 # ------------------------------------------------
|
|
134 add: add_test.o
|
|
135 $(CC) $(LFLAGS) -o add add_test.o
|
|
136
|
|
137 addtst: add add_test.dta
|
|
138 add < add_test.dta > /dev/null
|