]> git.saurik.com Git - apple/ld64.git/blob - unit-tests/test-cases/dwarf-strip-objc/Makefile
ld64-264.3.102.tar.gz
[apple/ld64.git] / unit-tests / test-cases / dwarf-strip-objc / Makefile
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
13 ifeq ($(FILEARCH),arm)
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
24 size -l hello-r.o | grep ${IMAGE_INFO} | ${PASS_IFF_STDIN}
25
26
27
28 clean:
29 rm -rf hello.o hello-r.o