summaryrefslogtreecommitdiff
path: root/data/boost/darwin.jam.diff
blob: 9503b9db250b7bcdac8b89babb53a553659ed6cf (plain)
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
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
--- a/tools/build/src/tools/darwin.jam	2018-08-01 15:50:55.000000000 -0500
+++ b/tools/build/src/tools/darwin.jam	2019-03-10 00:29:34.859932848 -0600
@@ -199,7 +199,7 @@
     }
     
     # - Initialize the SDKs available in the root for this tool.
-    local sdks = [ init-available-sdk-versions $(condition) : $(root) ] ;
+#    local sdks = [ init-available-sdk-versions $(condition) : $(root) ] ;
     
     #~ ECHO --- ;
     #~ ECHO --- bin :: $(bin) ;
@@ -213,200 +213,6 @@
     #~ EXIT ;
 }
 
-# Add and set options for a discovered SDK version.
-local rule init-sdk ( condition * : root ? : version + : version-feature ? )
-{
-    local rule version-to-feature ( version + )
-    {
-        switch $(version[1])
-        {
-            case appletv* :
-            {
-                return $(version[1])-$(version[2-]:J=.) ;
-            }
-            case iphone* :
-            {
-                return $(version[1])-$(version[2-]:J=.) ;
-            }
-            case mac* :
-            {
-                return $(version[2-]:J=.) ;
-            }
-            case * :
-            {
-                return $(version:J=.) ;
-            }
-        }
-    }
-    
-    if $(version-feature)
-    {
-        if $(.debug-configuration)
-        {
-            ECHO notice\: available sdk for $(condition)/<macosx-version>$(version-feature) at $(root) ;
-        }
-        
-        # Add the version to the features for specifying them.
-        if ! $(version-feature) in [ feature.values macosx-version ]
-        {
-            feature.extend macosx-version : $(version-feature) ;
-        }
-        if ! $(version-feature) in [ feature.values macosx-version-min ]
-        {
-            feature.extend macosx-version-min : $(version-feature) ;
-        }
-        
-        # Set the flags the version needs to compile with, first
-        # generic options.
-        flags darwin.compile OPTIONS $(condition)/<macosx-version>$(version-feature)
-            : -isysroot $(root) ;
-        flags darwin.link OPTIONS $(condition)/<macosx-version>$(version-feature)
-            : -isysroot $(root) ;
-        
-        # Then device variation options.
-        switch $(version[1])
-        {
-            case appletvsim* :
-            {
-                local N = $(version[2]) ;
-                if ! $(version[3]) { N += 00 ; }
-                else if [ regex.match (..) : $(version[3]) ] { N += $(version[3]) ; }
-                else { N += 0$(version[3]) ; }
-                if ! $(version[4]) { N += 00 ; }
-                else if [ regex.match (..) : $(version[4]) ] { N += $(version[4]) ; }
-                else { N += 0$(version[4]) ; }
-                N = $(N:J=) ;
-                flags darwin.compile OPTIONS <macosx-version-min>$(version-feature)
-                    : -D__IPHONE_OS_VERSION_MIN_REQUIRED=$(N) ;
-                flags darwin.link OPTIONS <macosx-version-min>$(version-feature)
-                    : -D__IPHONE_OS_VERSION_MIN_REQUIRED=$(N) ;
-            }
-
-            case appletv* :
-            {
-                flags darwin.compile OPTIONS <macosx-version-min>$(version-feature)
-                    : -mtvos-version-min=$(version[2-]:J=.) ;
-                flags darwin.link OPTIONS <macosx-version-min>$(version-feature)
-                    : -mtvos-version-min=$(version[2-]:J=.) ;
-            }
-
-            case iphonesim* :
-            {
-                local N = $(version[2]) ;
-                if ! $(version[3]) { N += 00 ; }
-                else if [ regex.match (..) : $(version[3]) ] { N += $(version[3]) ; }
-                else { N += 0$(version[3]) ; }
-                if ! $(version[4]) { N += 00 ; }
-                else if [ regex.match (..) : $(version[4]) ] { N += $(version[4]) ; }
-                else { N += 0$(version[4]) ; }
-                N = $(N:J=) ;
-                flags darwin.compile OPTIONS <macosx-version-min>$(version-feature)
-                    : -D__IPHONE_OS_VERSION_MIN_REQUIRED=$(N) ;
-                flags darwin.link OPTIONS <macosx-version-min>$(version-feature)
-                    : -D__IPHONE_OS_VERSION_MIN_REQUIRED=$(N) ;
-            }
-
-            case iphone* :
-            {
-                flags darwin.compile OPTIONS <macosx-version-min>$(version-feature)
-                    : -miphoneos-version-min=$(version[2-]:J=.) ;
-                flags darwin.link OPTIONS <macosx-version-min>$(version-feature)
-                    : -miphoneos-version-min=$(version[2-]:J=.) ;
-            }
-            
-            case mac* :
-            {
-                flags darwin.compile OPTIONS <macosx-version-min>$(version-feature)
-                    : -mmacosx-version-min=$(version[2-]:J=.) ;
-                flags darwin.link OPTIONS <macosx-version-min>$(version-feature)
-                    : -mmacosx-version-min=$(version[2-]:J=.) ;
-            }
-        }
-        
-        if $(version[3]) > 0
-        {
-            # We have a minor version of an SDK. We want to set up
-            # previous minor versions, plus the current minor version.
-            # So we recurse to set up the previous minor versions, up to
-            # the current version.
-            local minor-minus-1 = [ CALC $(version[3]) - 1 ] ;
-            return
-                [ init-sdk $(condition) : $(root)
-                    : $(version[1-2]) $(minor-minus-1) : [ version-to-feature $(version[1-2]) $(minor-minus-1) ] ]
-                $(version-feature) ;
-        }
-        else
-        {
-            return $(version-feature) ;
-        }
-    }
-    else if $(version[4])
-    {
-        # We have a patch version of an SDK. We want to set up
-        # both the specific patch version, and the minor version.
-        # So we recurse to set up the patch version. Plus the minor version.
-        return
-            [ init-sdk $(condition) : $(root)
-                : $(version[1-3]) : [ version-to-feature $(version[1-3]) ] ]
-            [ init-sdk $(condition) : $(root)
-                : $(version) : [ version-to-feature $(version) ] ] ;
-    }
-    else
-    {
-        # Yes, this is intentionally recursive.
-        return
-            [ init-sdk $(condition) : $(root)
-                : $(version) : [ version-to-feature $(version) ] ] ;
-    }
-}
-
-# Determine the MacOSX SDK versions installed and their locations.
-local rule init-available-sdk-versions ( condition * : root ? )
-{
-    root ?= /Developer ;
-    local sdks-root = $(root)/SDKs ;
-    local sdks = [ GLOB $(sdks-root) : MacOSX*.sdk AppleTVOS*.sdk AppleTVSimulator*.sdk iPhoneOS*.sdk iPhoneSimulator*.sdk ] ;
-    local result ;
-    for local sdk in $(sdks)
-    {
-        local sdk-match = [ MATCH "([^0-9]+)([0-9]+)[.]([0-9x]+)[.]?([0-9x]+)?" : $(sdk:D=) ] ;
-        local sdk-platform = $(sdk-match[1]:L) ;
-        local sdk-version = $(sdk-match[2-]) ;
-        if $(sdk-version)
-        {
-            switch $(sdk-platform)
-            {
-                case macosx :
-                {
-                    sdk-version = mac $(sdk-version) ;
-                }
-                case appletvos :
-                {
-                    sdk-version = appletv $(sdk-version) ;
-                }
-                case appletvsimulator :
-                {
-                    sdk-version = appletvsim $(sdk-version) ;
-                }
-                case iphoneos :
-                {
-                    sdk-version = iphone $(sdk-version) ;
-                }
-                case iphonesimulator :
-                {
-                    sdk-version = iphonesim $(sdk-version) ;
-                }
-                case * :
-                {
-                    sdk-version = $(sdk-version:J=-) ;
-                }
-            }
-            result += [ init-sdk $(condition) : $(sdk) : $(sdk-version) ] ;
-        }
-    }
-    return $(result) ;
-}
-
 # Generic options.
 flags darwin.compile OPTIONS <flags> ;
 
@@ -497,14 +303,14 @@
             }
         }
         
-        case arm :
-        {
-            if $(instruction-set) {
-                options = -arch$(_)$(instruction-set) ;
-            } else {
-                options = -arch arm ;
-            }
-        }
+#        case arm :
+#        {
+#            if $(instruction-set) {
+#                options = -arch$(_)$(instruction-set) ;
+#            } else {
+#                options = -arch arm ;
+#            }
+#        }
     }
     
     if $(options)