ObjFW  Check-in [974b1b203f]

Overview
Comment:Always build tests

However, they're only run when not cross-compiling or if a test launcher
is available.

Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 974b1b203f6c928c0b7b9b817a6d9f8344ea92713e8b6a42830e1e329d7363e6
User & Date: js on 2014-05-05 00:14:06
Other Links: manifest | tags
Context
2014-05-05
01:08
Improve atomics API check-in: a92844520a user: js tags: trunk
00:14
Always build tests check-in: 974b1b203f user: js tags: trunk
2014-05-04
23:57
Move -[setStringValue:] to OFXMLNode check-in: bb63873748 user: js tags: trunk
Changes

Modified Makefile from [b28336ecd2] to [a5b8cc4591].

1
2
3

4
5
6
7
8
9
10
11
12
13
14
15

16
17
18
19
20
21
22
1
2

3
4
5
6
7
8
9
10
11
12
13
14

15
16
17
18
19
20
21
22


-
+











-
+







include extra.mk

SUBDIRS = src utils ${TESTS}
SUBDIRS = src utils tests
DISTCLEAN = Info.plist		\
	    aclocal.m4		\
	    autom4te.cache	\
	    buildsys.mk		\
	    config.h		\
	    config.log		\
	    config.status	\
	    extra.mk

include buildsys.mk

utils ${TESTS}: src
utils tests: src

tarball:
	echo "Generating tarball for version ${PACKAGE_VERSION}..."
	rm -fr objfw-${PACKAGE_VERSION} objfw-${PACKAGE_VERSION}.tar \
		objfw-${PACKAGE_VERSION}.tar.xz
	mkdir objfw-${PACKAGE_VERSION}
	git --work-tree=objfw-${PACKAGE_VERSION} checkout .

Modified configure.ac from [ec91a3337d] to [006f8182a1].

943
944
945
946
947
948
949
950

951
952
953
954
955
956
957
958
959
960
961
962
963

964
965
966
967
968

969
970
971
972
973
974
975
943
944
945
946
947
948
949

950
951
952
953
954
955
956
957
958
959
960
961
962

963
964
965
966
967

968
969
970
971
972
973
974
975







-
+












-
+




-
+







	AC_SUBST(BIN_PREFIX, "${host_alias}-")

	case "$host" in
		*-*-mingw*)
			AC_CHECK_PROG(WINE, wine, wine)

			AS_IF([test x"$WINE" != x""], [
				AC_SUBST(TESTS, "tests")
				AC_SUBST(RUN_TESTS, "run")
				AC_SUBST(TEST_LAUNCHER, "$WINE")
			])
			;;
	esac

	AS_IF([test x"$with_wii" = x"yes"], [
		dnl Keep this lowercase, as WIILOAD is a variable used by
		dnl wiiload and thus likely already set by the user to something
		dnl that is not the path of the wiiload binary.
		AC_CHECK_PROG(wiiload, wiiload, wiiload)

		AS_IF([test x"$wiiload" != x""], [
			AC_SUBST(TESTS, "tests")
			AC_SUBST(RUN_TESTS, "run")
			AC_SUBST(TEST_LAUNCHER, "$wiiload")
		])
	])
], [
	AC_SUBST(TESTS, "tests")
	AC_SUBST(RUN_TESTS, "run")
])

dnl We don't call AC_PROG_CPP, but only AC_PROG_OBJCPP and set CPP to OBJCPP
dnl and add OBJCPPFLAGS to CPPFLAGS, thus we need to AC_SUBST these ourself.
AC_SUBST(CPP)
AC_SUBST(CPPFLAGS)
dnl We use the ObjC compiler as our assembler

Modified extra.mk.in from [b747bd17c6] to [41d3c65d8c].

39
40
41
42
43
44
45

46
47
48
49
50
51
52
53
54
39
40
41
42
43
44
45
46
47

48
49
50
51
52
53
54







+

-







PROPERTIESTESTS_M = @PROPERTIESTESTS_M@
REEXPORT_LIBOBJC = @REEXPORT_LIBOBJC@
RUNTIME = @RUNTIME@
RUNTIME_A = @RUNTIME_A@
RUNTIME_RUNTIME_A = @RUNTIME_RUNTIME_A@
RUNTIME_RUNTIME_LIB_A = @RUNTIME_RUNTIME_LIB_A@
RUNTIME_LIB_A = @RUNTIME_LIB_A@
RUN_TESTS = @RUN_TESTS@
TESTPLUGIN = @TESTPLUGIN@
TESTS = @TESTS@
TESTS_LIBS = @TESTS_LIBS@
TEST_LAUNCHER = @TEST_LAUNCHER@
USE_INCLUDES_THREADS = @USE_INCLUDES_THREADS@
USE_SRCS_FILES = @USE_SRCS_FILES@
USE_SRCS_PLUGINS = @USE_SRCS_PLUGINS@
USE_SRCS_SOCKETS = @USE_SRCS_SOCKETS@
USE_SRCS_THREADS = @USE_SRCS_THREADS@

Modified tests/Makefile from [ad5b11b1c1] to [61c7405dc1].

39
40
41
42
43
44
45
46




47
48

49
50
51
52
53
54
55
39
40
41
42
43
44
45
46
47
48
49
50
51

52
53
54
55
56
57
58
59








+
+
+
+

-
+







SRCS_PLUGINS = OFPluginTests.m
SRCS_SOCKETS = OFTCPSocketTests.m	\
	       OFUDPSocketTests.m
SRCS_THREADS = OFThreadTests.m

IOS_USER ?= mobile
IOS_TMP ?= /tmp/objfw-test

include ../buildsys.mk

post-all: ${RUN_TESTS}

.PHONY: run run-on-ios run-on-android sign-for-ios
run: all
run:
	rm -f libobjfw.so.${OBJFW_LIB_MAJOR}
	rm -f libobjfw.so.${OBJFW_LIB_MAJOR_MINOR}
	rm -f libobjfw.dll libobjfw.dylib
	if test -f ../src/libobjfw.so; then \
		${LN_S} ../src/libobjfw.so libobjfw.so.${OBJFW_LIB_MAJOR}; \
		${LN_S} ../src/libobjfw.so \
			libobjfw.so.${OBJFW_LIB_MAJOR_MINOR}; \
107
108
109
110
111
112
113


114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130




131
132
133
134







+
+











-
-
-
-




	psp-fixup-imports ${PROG_NOINST}
	mksfo "ObjFW Tests" PARAM.SFO
	psp-strip ${PROG_NOINST}
	pack-pbp $@ PARAM.SFO NULL NULL NULL NULL NULL ${PROG_NOINST} NULL

boot.dol: ${PROG_NOINST}
	elf2dol ${PROG_NOINST} $@

${PROG_NOINST}: ${LIBOBJFW_DEP}

${PROG_NOINST}.arm9: ${PROG_NOINST}
	arm-none-eabi-objcopy -O binary $< $@

${PROG_NOINST}.nds: ${PROG_NOINST}.arm9
	rm -fr nds-data
	mkdir -p nds-data
	cp testfile.bin testfile.txt testfile.ini serialization.xml nds-data
	ndstool -c $@ -9 $< -d nds-data
	rm -fr nds-data

include ../buildsys.mk

${PROG_NOINST}: ${LIBOBJFW_DEP}

CPPFLAGS += -I../src -I../src/exceptions -I../src/runtime -I.. -DSTDOUT
LIBS := -L../src -lobjfw ${TESTS_LIBS} ${LIBS}
LDFLAGS += ${MAP_LDFLAGS}
LD = ${OBJC}