]>
Commit | Line | Data |
---|---|---|
d696c285 A |
1 | # stuff to include in every test Makefile |
2 | ||
3 | SHELL = /bin/sh | |
4 | ||
5 | # set default to be host | |
6 | ARCH ?= $(shell arch) | |
7 | ||
8 | # set default to be all | |
9 | VALID_ARCHS ?= "ppc ppc64 i386" | |
10 | ||
11 | # if run within Xcode, add the just built tools to the command path | |
12 | ifdef BUILT_PRODUCTS_DIR | |
13 | PATH := ${BUILT_PRODUCTS_DIR}:${PATH} | |
14 | endif | |
15 | ||
16 | LD = ld | |
17 | OBJECTDUMP = ObjectDump | |
18 | MACHOCHECK = machocheck | |
19 | ||
20 | OTOOL = otool | |
21 | ifeq (${ARCH},ppc64) | |
22 | OTOOL = otool64 | |
23 | endif | |
69a49097 A |
24 | ifeq (${ARCH},x86_64) |
25 | OTOOL = otool64 | |
26 | endif | |
d696c285 A |
27 | |
28 | ||
29 | CC = gcc-4.0 -arch ${ARCH} | |
69a49097 | 30 | CCFLAGS = -Wall -std=c99 |
d696c285 A |
31 | ASMFLAGS = |
32 | ||
33 | CXX = g++-4.0 -arch ${ARCH} | |
69a49097 | 34 | CXXFLAGS = -Wall |
d696c285 A |
35 | |
36 | RM = rm | |
37 | RMFLAGS = -rf | |
38 | ||
39 | # utilites for Makefiles | |
40 | PASS_IFF = ${TESTROOT}/bin/pass-iff-exit-zero.pl | |
41 | PASS_IFF_EMPTY = ${TESTROOT}/bin/pass-iff-no-stdin.pl | |
42 | PASS_IFF_STDIN = ${TESTROOT}/bin/pass-iff-stdin.pl | |
43 | PASS_IFF_GOOD_MACHO = ${TESTROOT}/bin/pass-iff-exit-zero.pl ${MACHOCHECK} | |
44 | FAIL_IFF = ${TESTROOT}/bin/fail-iff-exit-zero.pl | |
45 | FAIL_IF_BAD_MACHO = ${TESTROOT}/bin/fail-if-exit-non-zero.pl ${MACHOCHECK} | |
46 | FAIL_IF_SUCCESS = ${TESTROOT}/bin/fail-if-exit-zero.pl | |
47 | FAIL_IF_EMPTY = ${TESTROOT}/bin/fail-if-no-stdin.pl | |
48 | FAIL_IF_STDIN = ${TESTROOT}/bin/fail-if-stdin.pl |