Skip to content

Commit ba5a14a

Browse files
committed
LIBGAMBIT: Fix building on iOS on current XCode
Backport of gambit/commit/a0dbbcb by @feeley
1 parent 9cd5d89 commit ba5a14a

File tree

1 file changed

+49
-0
lines changed

1 file changed

+49
-0
lines changed

libraries/libgambit/ios.patch

Lines changed: 49 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,49 @@
1+
--- lib/os_shell.c
2+
+++ lib/os_shell.c
3+
@@ -1,6 +1,6 @@
4+
/* File: "os_shell.c" */
5+
6+
-/* Copyright (c) 1994-2017 by Marc Feeley, All Rights Reserved. */
7+
+/* Copyright (c) 1994-2019 by Marc Feeley, All Rights Reserved. */
8+
9+
/*
10+
* This module implements the operating system specific routines
11+
@@ -808,6 +808,15 @@ ___SCMOBJ ___os_environ ___PVOID
12+
/* Shell command. */
13+
14+
15+
+#define ___USE_system
16+
+
17+
+#ifdef TARGET_OS_IPHONE
18+
+#if TARGET_OS_IPHONE == 1
19+
+#undef ___USE_system
20+
+#endif
21+
+#endif
22+
+
23+
+
24+
#if 1
25+
26+
___SCMOBJ ___os_shell_command
27+
@@ -816,6 +825,9 @@ ___SCMOBJ ___os_shell_command
28+
___SCMOBJ cmd;)
29+
{
30+
___SCMOBJ e;
31+
+
32+
+#ifdef ___USE_system
33+
+
34+
char *ccmd;
35+
36+
if ((e = ___SCMOBJ_to_NONNULLCHARSTRING
37+
@@ -842,6 +854,12 @@ ___SCMOBJ cmd;)
38+
___release_string (ccmd);
39+
}
40+
41+
+#else
42+
+
43+
+ e = ___UNIMPL_ERR;
44+
+
45+
+#endif
46+
+
47+
return e;
48+
}
49+

0 commit comments

Comments
 (0)