ObjFW  Check-in [74857232b0]

Overview
Comment:Clean up .travis.yml by moving out scripts
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA3-256: 74857232b008e400e5e6fb76b27dbfd6626a4bc229e7ef33652a747f5df12c17
User & Date: js on 2020-11-01 13:08:20
Other Links: manifest | tags
Context
2020-11-02
00:53
OFSystemInfo: Use cpuid to get CPU model check-in: acb2130974 user: js tags: trunk
2020-11-01
13:08
Clean up .travis.yml by moving out scripts check-in: 74857232b0 user: js tags: trunk
11:35
OFString: Add -[substring{From,To}Index:] check-in: 4bbac7ab17 user: js tags: trunk
Changes

Modified .travis.yml from [159ce14eb5] to [0619e15749].

240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
      dist: bionic
      env:
        - config=wii

services: docker

before_install:
  - if [ "$TRAVIS_OS_NAME" = "linux" -a -z "$config" ]; then
            case "$TRAVIS_CPU_ARCH" in
                    amd64 | s390x)
                            pkgs="gobjc-multilib";
                            ;;
                    *)
                            pkgs="gobjc";
                            ;;
            esac;

            pkgs="$pkgs libsctp-dev";

            if grep precise /etc/lsb-release >/dev/null; then
                    pkgs="$pkgs ipx";
            fi;

            if ! sudo apt-get -qq install -y $pkgs >/tmp/apt_log 2>&1; then
                    cat /tmp/apt_log;
                    exit 1;
            fi;

            if grep precise /etc/lsb-release >/dev/null; then
                    sudo ipx_internal_net add 1234 123456;
            fi;
    fi

  - if [ "$config" = "nintendo_3ds" -o "$config" = "nintendo_ds" ]; then
            docker pull devkitpro/devkitarm;
    fi

  - if [ "$config" = "wii" ]; then
            docker pull devkitpro/devkitppc;
    fi

  - if [ "$config" = "amigaos" ]; then
            wget -q https://franke.ms/download/amiga-gcc.tgz;
            tar -C / -xzf amiga-gcc.tgz;
    fi

script:
  - build() {
            if ! git clean -fxd >/tmp/clean_log 2>&1; then
                    cat /tmp/clean_log;
                    exit 1;
            fi;
            ./autogen.sh || exit 1;
            .travis/build.sh "$@" || exit 1;
    }

  - if [ "$TRAVIS_OS_NAME" = "linux" -a -z "$config" ]; then
            build_32_64() {
                    build OBJC="$CC" $@;

                    case "$TRAVIS_CPU_ARCH" in
                            amd64)
                                    build OBJC="$CC -m32"
                                          --host=i686-pc-linux-gnu $@;
                                    ;;
                            s390x)
                                    build OBJC="$CC -m31"
                                          --host=s390-pc-linux-gnu $@;
                                    ;;
                    esac
            };

            build_32_64;
            build_32_64 --enable-seluid24;
            build_32_64 --disable-compiler-tls;

            true The following are not CPU-dependent, so only run them on amd64;
            if [ "$TRAVIS_CPU_ARCH" = "amd64" ]; then
                    build_32_64 --disable-threads;
                    build_32_64 --disable-threads --disable-sockets;
                    build_32_64 --disable-threads --disable-files;
                    build_32_64 --disable-threads --disable-sockets
                                --disable-files;
                    build_32_64 --disable-sockets;
                    build_32_64 --disable-sockets --disable-files;
                    build_32_64 --disable-files;
                    build_32_64 --disable-shared;
                    build_32_64 --disable-shared --enable-seluid24;
                    build_32_64 --disable-compiler-tls --disable-threads;
            fi;
    fi

  - if [ "$TRAVIS_OS_NAME" = "osx" -a -z "$config" ]; then
            build_mac_32_64() {
                    build $@;
                    if [ -z "$no32bit" ]; then
                            build OBJC="clang -m32" --host=i386-apple-darwin $@;
                    fi;
            };

            if xcodebuild -version | grep 'Xcode 6' >/dev/null; then
                    export CPPFLAGS="-D_Nullable=__nullable
                                     -D_Nonnull=__nonnull
                                     -D_Null_unspecified=__null_unspecified";
            fi;

            build_mac_32_64;
            build_mac_32_64 --disable-threads;
            build_mac_32_64 --disable-threads --disable-sockets;
            build_mac_32_64 --disable-threads --disable-files;
            build_mac_32_64 --disable-threads --disable-sockets --disable-files;
            build_mac_32_64 --disable-sockets;
            build_mac_32_64 --disable-sockets --disable-files;
            build_mac_32_64 --disable-files;
            build_mac_32_64 --disable-shared;
            if [ -z "$noruntime" ]; then
                    build_mac_32_64 --enable-runtime;
                    build_mac_32_64 --enable-runtime --enable-seluid24;
                    build_mac_32_64 --enable-runtime --disable-threads;
                    build_mac_32_64 --enable-runtime --disable-threads
                                    --disable-sockets;
                    build_mac_32_64 --enable-runtime --disable-threads
                                    --disable-files;
                    build_mac_32_64 --enable-runtime --disable-threads
                                    --disable-sockets --disable-files;
                    build_mac_32_64 --enable-runtime --disable-sockets;
                    build_mac_32_64 --enable-runtime --disable-sockets
                                    --disable-files;
                    build_mac_32_64 --enable-runtime --disable-files;
                    build_mac_32_64 --enable-runtime --disable-shared;
                    build_mac_32_64 --enable-runtime --disable-shared
                                    --enable-seluid24;
            fi;
    fi

  - if [ "$config" = "ios" ]; then
            if xcodebuild -version | grep 'Xcode 6' >/dev/null; then
                    export CPPFLAGS="-D_Nullable=__nullable
                                     -D_Nonnull=__nonnull
                                     -D_Null_unspecified=__null_unspecified";
            fi;

            export IPHONEOS_DEPLOYMENT_TARGET="9.0";
            clang="clang -isysroot $(xcrun --sdk iphoneos --show-sdk-path)";
            export OBJC="$clang -arch armv7 -arch arm64";
            export OBJCPP="$clang -arch armv7 -E";
            build --host=arm-apple-darwin --enable-static;

            sysroot="$(xcrun --sdk iphonesimulator --show-sdk-path)";
            clang="clang -isysroot $sysroot";
            export OBJC="$clang -arch i386 -arch x86_64";
            export OBJCPP="$clang -arch i386 -E";
            build WRAPPER=true --host=i386-apple-darwin --enable-static;
    fi

  - if [ "$config" = "amigaos" ]; then
            export PATH="/opt/amiga/bin:$PATH";

            build --host=m68k-amigaos;
            build --host=m68k-amigaos --disable-amiga-lib;
            build --host=m68k-amigaos --enable-static;
    fi

  - if [ "$config" = "nintendo_3ds" ]; then
            ./autogen.sh;
            docker run -e DEVKITPRO=/opt/devkitpro
                    -e PATH="/opt/devkitpro/devkitARM/bin:$PATH"
                    -v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitarm
                    /objfw/.travis/build.sh --host=arm-none-eabi --with-3ds;
    fi

  - if [ "$config" = "nintendo_ds" ]; then
            ./autogen.sh;
            docker run -e DEVKITPRO=/opt/devkitpro
                    -e PATH="/opt/devkitpro/devkitARM/bin:$PATH"
                    -v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitarm
                    /objfw/.travis/build.sh --host=arm-none-eabi --with-nds;
    fi

  - if [ "$config" = "wii" ]; then
            ./autogen.sh;
            docker run -e DEVKITPRO=/opt/devkitpro
                    -e PATH="/opt/devkitpro/devkitPPC/bin:$PATH"
                    -v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitppc
                    /objfw/.travis/build.sh ac_cv_prog_wiiload=
                    --host=powerpc-eabi --with-wii;
    fi







<
<
<
<
<
<
<
<
<
|
<

<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<

<
<
<
<
<
<
<
<
|
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
<
240
241
242
243
244
245
246









247

248



























249








250



































































































































      dist: bionic
      env:
        - config=wii

services: docker

before_install:









  - .travis/before_install.sh





























script:








  - .travis/script.sh



































































































































Added .travis/before_install.sh version [479fa2374a].































































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
#!/bin/sh
if [ "$TRAVIS_OS_NAME" = "linux" -a -z "$config" ]; then
	case "$TRAVIS_CPU_ARCH" in
		amd64 | s390x)
			pkgs="gobjc-multilib"
			;;
		*)
			pkgs="gobjc"
			;;
	esac

	pkgs="$pkgs libsctp-dev"

	if grep precise /etc/lsb-release >/dev/null; then
		pkgs="$pkgs ipx"
	fi

	# We don't need any of them and they're often broken.
	sudo rm -f /etc/apt/sources.list.d/*

	if ! sudo apt-get -qq update >/tmp/apt_log 2>&1; then
		cat /tmp/apt_log
		exit 1
	fi

	if ! sudo apt-get -qq install -y $pkgs >>/tmp/apt_log 2>&1; then
		cat /tmp/apt_log
		exit 1
	fi

	if grep precise /etc/lsb-release >/dev/null; then
		sudo ipx_internal_net add 1234 123456
	fi
fi

if [ "$config" = "nintendo_3ds" -o "$config" = "nintendo_ds" ]; then
	docker pull devkitpro/devkitarm
fi

if [ "$config" = "wii" ]; then
	docker pull devkitpro/devkitppc
fi

if [ "$config" = "amigaos" ]; then
	wget -q https://franke.ms/download/amiga-gcc.tgz
	tar -C / -xzf amiga-gcc.tgz
fi

Added .travis/script.sh version [6432052d0a].































































































































































































































































































>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
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
133
134
135
136
137
138
139
140
141
142
143
#!/bin/sh
build() {
	if ! git clean -fxd >/tmp/clean_log 2>&1; then
		cat /tmp/clean_log
		exit 1
	fi

	./autogen.sh || exit 1
	.travis/build.sh "$@" || exit 1
}

if [ "$TRAVIS_OS_NAME" = "linux" -a -z "$config" ]; then
	build_32_64() {
		build OBJC="$CC" $@

		case "$TRAVIS_CPU_ARCH" in
			amd64)
				build OBJC="$CC -m32" \
					--host=i686-pc-linux-gnu $@
				;;
			s390x)
				build OBJC="$CC -m31" \
					--host=s390-pc-linux-gnu $@
				;;
		esac
	}

	build_32_64
	build_32_64 --enable-seluid24
	build_32_64 --disable-compiler-tls

	# The following are not CPU-dependent, so only run them on amd64
	if [ "$TRAVIS_CPU_ARCH" = "amd64" ]; then
		build_32_64 --disable-threads
		build_32_64 --disable-threads --disable-sockets
		build_32_64 --disable-threads --disable-files
		build_32_64 --disable-threads --disable-sockets --disable-files
		build_32_64 --disable-sockets
		build_32_64 --disable-sockets --disable-files
		build_32_64 --disable-files
		build_32_64 --disable-shared
		build_32_64 --disable-shared --enable-seluid24
		build_32_64 --disable-compiler-tls --disable-threads
	fi
fi

if [ "$TRAVIS_OS_NAME" = "osx" -a -z "$config" ]; then
	build_mac_32_64() {
		build $@

		if [ -z "$no32bit" ]; then
			build OBJC="clang -m32" --host=i386-apple-darwin $@
		fi
	}

	if xcodebuild -version | grep 'Xcode 6' >/dev/null; then
		export CPPFLAGS="-D_Null_unspecified=__null_unspecified"
		export CPPFLAGS="$CPPFLAGS -D_Nullable=__nullable"
		export CPPFLAGS="$CPPFLAGS -D_Nonnull=__nonnull"
	fi

	build_mac_32_64
	build_mac_32_64 --disable-threads
	build_mac_32_64 --disable-threads --disable-sockets
	build_mac_32_64 --disable-threads --disable-files
	build_mac_32_64 --disable-threads --disable-sockets --disable-files
	build_mac_32_64 --disable-sockets
	build_mac_32_64 --disable-sockets --disable-files
	build_mac_32_64 --disable-files
	build_mac_32_64 --disable-shared

	if [ -z "$noruntime" ]; then
		build_mac_32_64 --enable-runtime
		build_mac_32_64 --enable-runtime --enable-seluid24
		build_mac_32_64 --enable-runtime --disable-threads
		build_mac_32_64 --enable-runtime --disable-threads \
				--disable-sockets
		build_mac_32_64 --enable-runtime --disable-threads \
				--disable-files
		build_mac_32_64 --enable-runtime --disable-threads \
				--disable-sockets --disable-files
		build_mac_32_64 --enable-runtime --disable-sockets
		build_mac_32_64 --enable-runtime --disable-sockets \
				--disable-files
		build_mac_32_64 --enable-runtime --disable-files
		build_mac_32_64 --enable-runtime --disable-shared
		build_mac_32_64 --enable-runtime --disable-shared \
				--enable-seluid24
	fi
fi

if [ "$config" = "ios" ]; then
	if xcodebuild -version | grep 'Xcode 6' >/dev/null; then
		export CPPFLAGS="-D_Null_unspecified=__null_unspecified"
		export CPPFLAGS="$CPPFLAGS -D_Nullable=__nullable"
		export CPPFLAGS="$CPPFLAGS -D_Nonnull=__nonnull"
	fi

	export IPHONEOS_DEPLOYMENT_TARGET="9.0"
	clang="clang -isysroot $(xcrun --sdk iphoneos --show-sdk-path)"
	export OBJC="$clang -arch armv7 -arch arm64"
	export OBJCPP="$clang -arch armv7 -E"
	build --host=arm-apple-darwin --enable-static

	sysroot="$(xcrun --sdk iphonesimulator --show-sdk-path)"
	clang="clang -isysroot $sysroot"
	export OBJC="$clang -arch i386 -arch x86_64"
	export OBJCPP="$clang -arch i386 -E"
	build WRAPPER=true --host=i386-apple-darwin --enable-static
fi

if [ "$config" = "amigaos" ]; then
	export PATH="/opt/amiga/bin:$PATH"

	build --host=m68k-amigaos
	build --host=m68k-amigaos --disable-amiga-lib
	build --host=m68k-amigaos --enable-static
fi

if [ "$config" = "nintendo_3ds" ]; then
	./autogen.sh
	docker run -e DEVKITPRO=/opt/devkitpro				\
		-e PATH="/opt/devkitpro/devkitARM/bin:$PATH"		\
		-v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitarm		\
		/objfw/.travis/build.sh --host=arm-none-eabi --with-3ds
fi

if [ "$config" = "nintendo_ds" ]; then
	./autogen.sh
	docker run -e DEVKITPRO=/opt/devkitpro				\
		-e PATH="/opt/devkitpro/devkitARM/bin:$PATH"		\
		-v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitarm		\
		/objfw/.travis/build.sh --host=arm-none-eabi --with-nds
fi

if [ "$config" = "wii" ]; then
	./autogen.sh
	docker run -e DEVKITPRO=/opt/devkitpro				\
		-e PATH="/opt/devkitpro/devkitPPC/bin:$PATH"		\
		-v $TRAVIS_BUILD_DIR:/objfw devkitpro/devkitppc		\
		/objfw/.travis/build.sh ac_cv_prog_wiiload=		\
		--host=powerpc-eabi --with-wii
fi