ObjFW  Diff

Differences From Artifact [b7c5e2f78b]:

To Artifact [e6fb754559]:


56
57
58
59
60
61
62

63

64
65
66

67
68
69
70
71
72
73
56
57
58
59
60
61
62
63

64

65

66
67
68
69
70
71
72
73







+
-
+
-

-
+







		AS_IF([test x"$enable_amiga_lib" != x"no"], [
			AC_SUBST(OBJFWRT_AMIGA_LIB, objfwrt68k.library)
			AC_SUBST(SFDC_TARGET, m68k-amigaos)
			AC_SUBST(SFD_FILE, amigaos3.sfd)
			AC_SUBST(SFDC_INLINE_H, inline.h)
			dnl For 68000, GCC emits calls to helper functions that
			dnl do not work properly in a library.
			t="-mcpu=68020 -fbaserel -noixemul"
			AC_SUBST(AMIGA_LIB_CFLAGS,
			AC_SUBST(AMIGA_LIB_CFLAGS, "$t -ffreestanding")
				"-mcpu=68020 -fbaserel -ffreestanding")
			AC_SUBST(AMIGA_LIB_LDFLAGS,
				"-mcpu=68020 -fbaserel -resident -nostartfiles")
				"$t -resident -nostartfiles")
		])

		AC_SUBST(LIBBASES_M, libbases.m)
		;;
	powerpc-*-amigaos*)
		CPPFLAGS="$CPPFLAGS -D__USE_INLINE__"

87
88
89
90
91
92
93
94

95
96
97

98
99
100
101
102
103
104
87
88
89
90
91
92
93

94
95
96

97
98
99
100
101
102
103
104







-
+


-
+







			enable_files="yes"	# Required for reading ENV:
			supports_amiga_lib="yes"
			check_pedantic="no"	# Breaks generated inlines

			AS_IF([test x"$enable_amiga_lib" != x"no"], [
				AC_SUBST(OBJFWRT_AMIGA_LIB, objfwrt.library)
				AC_SUBST(CVINCLUDE_INLINE_H, inline.h)
				t="-mresident32 -ffreestanding"
				t="-mresident32 -ffreestanding -noixemul"
				AC_SUBST(AMIGA_LIB_CFLAGS, $t)
				t="-mresident32 -nostartfiles -nodefaultlibs"
				t="$t -lc"
				t="$t -noixemul -lc"
				AC_SUBST(AMIGA_LIB_LDFLAGS, $t)
			])

			AC_SUBST(LIBBASES_M, libbases.m)
		])

		enable_shared="no"
247
248
249
250
251
252
253








254
255
256
257
258
259
260
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268







+
+
+
+
+
+
+
+







			dnl accept everything used in ObjFW's assembly files.
			dnl Therefore, use the integrated assembler for ObjC
			dnl files, but not for assembly files.
			mips*-*-*)
				flag="-integrated-as"
				OBJCFLAGS="$OBJCFLAGS $flag"
				OBJFW_OBJCFLAGS="$OBJFW_OBJCFLAGS $flag"
				;;
			dnl Don't use -no-integrated-as on Darwin. It breaks
			dnl building for the iOS simulator.
			i?86-*-darwin* | x86_64-*-darwin*)
				;;
			dnl Many older Clang versions don't support jmp short.
			i?86-*-* | x86_64-*-*)
				ASFLAGS="$ASFLAGS -no-integrated-as"
				;;
			dnl Clang's assembler on Windows is not complete yet
			dnl and cannot compile all .S files.
			*-*-mingw*)
				ASFLAGS="$ASFLAGS -no-integrated-as"
				;;
			dnl Clang generates assembly output on SPARC64 that
595
596
597
598
599
600
601
602
603
604
605
606
607








608
609
610
611
612
613
614
615
603
604
605
606
607
608
609






610
611
612
613
614
615
616
617

618
619
620
621
622
623
624







-
-
-
-
-
-
+
+
+
+
+
+
+
+
-








			AC_MSG_RESULT($exception_type)
		], [
			AC_MSG_RESULT(exceptions unavailable!)
			AC_MSG_ERROR([Exceptions not accepted by compiler!])
		])

		AC_CHECK_FUNC($raise_exception, [], [
			AC_CHECK_LIB(c++, $raise_exception, [
				LIBS="-lc++ -lc++abi -lpthread $LIBS"
			], [
				AC_MSG_ERROR([_Unwind_RaiseException missing!])
			], [-lc++abi -lpthread])
		AC_SEARCH_LIBS($raise_exception, [c++abi gcc_s gcc], [
			dnl c++abi requires pthread on OpenBSD
			AS_IF([test x"$ac_lib" = x"c++abi"], [
				LIBS="$LIBS -lpthread"
			])
		], [
			AC_MSG_ERROR([$raise_exception missing!])
		], [-lpthread])
		])

		AC_CHECK_FUNCS(_Unwind_GetDataRelBase _Unwind_GetTextRelBase)
		;;
	"Apple runtime")
		AC_DEFINE(OF_APPLE_RUNTIME, 1,
			[Whether we use the Apple ObjC runtime])