X-Git-Url: https://git.saurik.com/apple/ld64.git/blobdiff_plain/69a49097222b02da1734b2c7a46b6ebb29f32fbc..77cc3118ce7a3a70a0a7364d77ae1eb766a477e7:/unit-tests/test-cases/rebase-basic/Makefile diff --git a/unit-tests/test-cases/rebase-basic/Makefile b/unit-tests/test-cases/rebase-basic/Makefile index 2077033..ba262aa 100644 --- a/unit-tests/test-cases/rebase-basic/Makefile +++ b/unit-tests/test-cases/rebase-basic/Makefile @@ -32,15 +32,22 @@ include ${TESTROOT}/include/common.makefile run: all all: - ${CC} -arch ${ARCH} -c foo.c -o foo.${ARCH}.o - ${CC} -arch ${ARCH} -c bar.m -o bar.${ARCH}.o - ${CC} -arch ${ARCH} foo.${ARCH}.o bar.${ARCH}.o -dynamiclib -o libfoo.${ARCH}.dylib -framework Foundation -single_module -mmacosx-version-min=10.5 - ${CC} -arch ${ARCH} foo.${ARCH}.o bar.${ARCH}.o -dynamiclib -o libfoo-alt.${ARCH}.dylib -framework Foundation -single_module -mmacosx-version-min=10.5 -seg1addr 0x12340000 -install_name libfoo.${ARCH}.dylib + ${CC} ${CCFLAGS} -c foo.c -o foo.${ARCH}.o + ${FAIL_IF_BAD_OBJ} foo.${ARCH}.o + + ${CC} ${CCFLAGS} -c bar.m -o bar.${ARCH}.o + ${FAIL_IF_BAD_OBJ} bar.${ARCH}.o + + ${CC} ${CCFLAGS} foo.${ARCH}.o bar.${ARCH}.o -dynamiclib -Wl,-no_uuid -o libfoo.${ARCH}.dylib -framework Foundation -framework CoreFoundation + ${FAIL_IF_BAD_MACHO} libfoo.${ARCH}.dylib + + ${CC} ${CCFLAGS} foo.${ARCH}.o bar.${ARCH}.o -dynamiclib -Wl,-no_uuid -o libfoo-alt.${ARCH}.dylib -framework Foundation -framework CoreFoundation -seg1addr 0x12340000 -install_name libfoo.${ARCH}.dylib + ${FAIL_IF_BAD_MACHO} libfoo-alt.${ARCH}.dylib + rebase -arch ${ARCH} -low_address 0x12340000 libfoo.${ARCH}.dylib ${FAIL_IF_BAD_MACHO} libfoo.${ARCH}.dylib + ${PASS_IFF} diff libfoo.${ARCH}.dylib libfoo-alt.${ARCH}.dylib clean: - rm foo.${ARCH}.o bar.${ARCH}.o libfoo.${ARCH}.dylib libfoo-alt.${ARCH}.dylib - - + rm *.o *.dylib