]> git.ipfire.org Git - thirdparty/binutils-gdb.git/blob - gdb/testsuite/gdb.hp/so-thresh.mk
* config/sh/tm-sh.h (BELIEVE_PCC_PROMOTION): Define, so that
[thirdparty/binutils-gdb.git] / gdb / testsuite / gdb.hp / so-thresh.mk
1 # Make file for so-thresh test
2
3 OBJDIR=.
4 SRCDIR=.
5 CFLAGS = +DA1.1 -g
6
7 # This is how to build this generator.
8 gen-so-thresh.o: ${SRCDIR}/gen-so-thresh.c
9 $(CC) $(CFLAGS) -o gen-so-thresh.o -c ${SRCDIR}/gen-so-thresh.c
10 gen-so-thresh: gen-so-thresh.o
11 $(CC) $(CFLAGS) -o gen-so-thresh gen-so-thresh.o
12
13 # This is how to run this generator.
14 # This target should be made before the 'all' target,
15 # to ensure that the shlib sources are all available.
16 require_shlibs: gen-so-thresh
17 if ! [ -a lib00-so-thresh.c ] ; then \
18 gen-so-thresh ; \
19 fi
20 if ! [ -a lib01-so-thresh.c ] ; then \
21 gen-so-thresh ; \
22 fi
23 if ! [ -a lib02-so-thresh.c ] ; then \
24 gen-so-thresh ; \
25 fi
26
27 # This is how to build all the shlibs.
28 # Be sure to first make the require_shlibs target!
29 lib00-so-thresh.o: lib00-so-thresh.c
30 $(CC) $(CFLAGS) +Z -o lib00-so-thresh.o -c lib00-so-thresh.c
31 lib00-so-thresh.sl: lib00-so-thresh.o
32 $(LD) $(LDFLAGS) -b -o lib00-so-thresh.sl lib00-so-thresh.o
33 lib01-so-thresh.o: lib01-so-thresh.c
34 $(CC) $(CFLAGS) +Z -o lib01-so-thresh.o -c lib01-so-thresh.c
35 lib01-so-thresh.sl: lib01-so-thresh.o
36 $(LD) $(LDFLAGS) -b -o lib01-so-thresh.sl lib01-so-thresh.o
37 lib02-so-thresh.o: lib02-so-thresh.c
38 $(CC) $(CFLAGS) +Z -o lib02-so-thresh.o -c lib02-so-thresh.c
39 lib02-so-thresh.sl: lib02-so-thresh.o
40 $(LD) $(LDFLAGS) -b -o lib02-so-thresh.sl lib02-so-thresh.o
41
42
43
44
45 # For convenience, here's names for all pieces of all shlibs.
46 SHLIB_SOURCES = \
47 lib00-so-thresh.c \
48 lib01-so-thresh.c \
49 lib02-so-thresh.c
50
51 SHLIB_OBJECTS = $(SHLIB_SOURCES:.c=.o)
52 SHLIBS = $(SHLIB_SOURCES:.c=.sl)
53 SHLIB_NAMES = $(SHLIB_SOURCES:.c=)
54 EXECUTABLES = $(SHLIBS) gen-so-thresh so-thresh
55 OBJECT_FILES = $(SHLIB_OBJECTS) gen-so-thresh.o so-thresh.o
56
57 shlib_objects: $(SHLIB_OBJECTS)
58 shlibs: $(SHLIBS)
59
60 # This is how to build the debuggable testcase that uses the shlibs.
61 so-thresh.o: so-thresh.c
62 $(CC) $(CFLAGS) -o so-thresh.o -c so-thresh.c
63 so-thresh: shlibs so-thresh.o
64 $(LD) $(LDFLAGS) -o so-thresh -lc -L${OBJDIR} -c so-thresh.linkopts /opt/langtools/lib/end.o /lib/crt0.o so-thresh.o
65
66 # Yeah, but you should first make the require_shlibs target!
67 all: so-thresh gen-so-thresh
68
69 # To remove everything built via this makefile...
70 clean:
71 rm -f lib0*-so-thresh.*
72 rm -f *.o gen-so-thresh so-thresh.linkopts so-thresh.c
73 rm -f so-thresh