]>
Commit | Line | Data |
---|---|---|
a645023d A |
1 | TESTROOT = ../.. |
2 | include ${TESTROOT}/include/common.makefile | |
3 | ||
4 | # | |
5 | # Verify that ld -r -S preserves the __objc_imageinfo section | |
6 | # | |
7 | ||
8 | IMAGE_INFO = "__image_info" | |
9 | ||
10 | ifeq ($(ARCH),x86_64) | |
11 | IMAGE_INFO = "__objc_imageinfo" | |
12 | endif | |
afe874b1 | 13 | ifeq ($(FILEARCH),arm) |
a645023d A |
14 | IMAGE_INFO = "__objc_imageinfo" |
15 | endif | |
16 | ||
17 | ||
18 | ||
19 | run: all | |
20 | ||
21 | all: | |
22 | ${CC} ${CCFLAGS} -gdwarf-2 hello.m -c -o hello.o | |
23 | ${LD} -r -S hello.o -o hello-r.o | |
0a8dc3df | 24 | size -m -l hello-r.o | grep ${IMAGE_INFO} | ${PASS_IFF_STDIN} |
a645023d A |
25 | |
26 | ||
27 | ||
28 | clean: | |
29 | rm -rf hello.o hello-r.o |