File tree Expand file tree Collapse file tree 9 files changed +134
-32
lines changed
Expand file tree Collapse file tree 9 files changed +134
-32
lines changed Original file line number Diff line number Diff line change 66 'host_sdk%' : 'macosx' ,
77
88 'output_dir' : '../ios-bin/<(target_sdk)' ,
9+
10+ 'mac_tools_dir' : '$(SOLUTION_DIR)/_build/ios/<(host_sdk)/$(CONFIGURATION)'
911 },
1012
1113 'xcode_config_file' : '../version' ,
1214
1315 'xcode_settings' :
1416 {
1517 'SDKROOT' : '<(target_sdk)' ,
18+ 'SUPPORTED_PLATFORMS' : 'iphoneos iphonesimulator' ,
1619
1720 'SOLUTION_DIR' : '<(DEPTH)' ,
1821 'SYMROOT' : '$(SOLUTION_DIR)/_build/ios/$(SDK_NAME)' ,
5255 'lib_suffix' : '.dylib' ,
5356 'ext_suffix' : '.so' ,
5457 'debug_info_suffix' : '.dSYM' ,
58+
59+ 'mac_tools_dir' : '$(SOLUTION_DIR)/_build/ios/<(host_sdk)/$(CONFIGURATION)'
5560 },
5661
62+ 'mac_bundle' : 0 ,
63+
5764 'defines' :
5865 [
5966 '_MOBILE' ,
125132 ],
126133 },
127134 ],
135+ [
136+ # If building a host tool, use the OSX settings
137+ '_toolset != "target"' ,
138+ {
139+ 'xcode_settings' :
140+ {
141+ 'SDKROOT[platform=macosx*]' : '<(host_sdk)' ,
142+ 'SUPPORTED_PLATFORMS' : 'macosx' ,
143+ 'ARCHS' : 'x86_64' ,
144+
145+ 'SYMROOT' : '$(SOLUTION_DIR)/_build/ios/<(host_sdk)' ,
146+ 'OBJROOT' : '$(SOLUTION_DIR)/_cache/ios/<(host_sdk)' ,
147+ },
148+ },
149+ ],
128150 ],
129151 },
130152
Original file line number Diff line number Diff line change 1111 'conditions' :
1212 [
1313 [
14- # Only the Linux and Android builds support proper cross-compilation
15- 'OS == "linux" or OS == "android"' ,
14+ 'cross_compile != 0' ,
1615 {
1716 'dependencies' :
1817 [
Original file line number Diff line number Diff line change 1212
1313 'toolsets' : ['host' ,'target' ],
1414
15+ 'product_name' : 'libFoundation' ,
16+
1517 'dependencies' :
1618 [
1719 '../prebuilt/libicu.gyp:libicu' ,
127129 ],
128130 },
129131
132+ 'target_conditions' :
133+ [
134+ [
135+ '_toolset != "target"' ,
136+ {
137+ 'product_name' : 'libFoundation->(_toolset)' ,
138+ },
139+ ],
140+ ],
141+
130142 'link_settings' :
131143 {
132144 'conditions' :
Original file line number Diff line number Diff line change 3636
3737 'toolsets' : ['host' ,'target' ],
3838
39+ 'product_name' : 'libScript' ,
40+
3941 'dependencies' :
4042 [
4143 '../libfoundation/libfoundation.gyp:libFoundation' ,
7880 },
7981 ],
8082 ],
83+
84+ 'target_conditions' :
85+ [
86+ [
87+ '_toolset != "target"' ,
88+ {
89+ 'product_name' : 'libScript->(_toolset)' ,
90+ },
91+ ],
92+ ],
8193 },
8294 {
8395 'target_name' : 'stdscript' ,
8496 'type' : 'static_library' ,
8597
8698 'toolsets' : ['host' ,'target' ],
8799
100+ 'product_name' : 'stdscript' ,
101+
88102 'dependencies' :
89103 [
90104 'libScript' ,
101115 [
102116 '<@(stdscript_sources)' ,
103117 ],
118+
119+ 'target_conditions' :
120+ [
121+ [
122+ '_toolset != "target"' ,
123+ {
124+ 'product_name' : 'stdscript->(_toolset)' ,
125+ },
126+ ],
127+ ],
104128 },
105129 ],
106130}
Original file line number Diff line number Diff line change 1414
1515 'suppress_warnings' : 1 ,
1616
17+ 'product_name' : 'grts' ,
18+
1719 'sources' :
1820 [
1921 'grts.c' ,
2022 ],
23+
24+ 'target_conditions' :
25+ [
26+ [
27+ '_toolset != "target"' ,
28+ {
29+ 'product_name' : 'grts->(_toolset)' ,
30+ },
31+ ],
32+ ],
2133 },
2234 ],
2335}
Original file line number Diff line number Diff line change 3636 'dependencies' :
3737 [
3838 'src/lc-compile-bootstrap.gyp:lc-compile-stage3#host' ,
39- 'src/lc-compile-bootstrap.gyp:lc-compile-stage4#target' ,
39+ ],
40+
41+ 'conditions' :
42+ [
43+ [
44+ 'mobile == 0' ,
45+ {
46+ 'dependencies' :
47+ [
48+ 'src/lc-compile-bootstrap.gyp:lc-compile-stage4#target' ,
49+ ],
50+ },
51+ ],
52+ [
53+ 'OS == "ios"' ,
54+ {
55+ 'direct_dependent_settings' :
56+ {
57+ 'variables' :
58+ {
59+ # Work-around for Xcode/Gyp impedance mismatch
60+ 'lc-compile_host' : '<(mac_tools_dir)/lc-compile-stage3-host' ,
61+ },
62+ },
63+ },
64+ ],
4065 ],
4166
4267 'direct_dependent_settings' :
Original file line number Diff line number Diff line change 1313 'dependencies' :
1414 [
1515 'lc-compile/lc-compile.gyp:lc-compile' ,
16- 'lc-compile/lc-run.gyp:lc-run' ,
16+ ],
17+
18+ 'conditions' :
19+ [
20+ [
21+ 'mobile == 0' ,
22+ {
23+ 'dependencies' :
24+ [
25+ 'lc-compile/lc-run.gyp:lc-run' ,
26+ ],
27+ },
28+ ],
1729 ],
1830 },
1931 ],
Original file line number Diff line number Diff line change @@ -96,7 +96,7 @@ sub trim
9696output " __libexports" ;
9797output " };" ;
9898output " LibInfo *__libinfoptr_$name __attribute__((__visibility__(\" default\" ))) = &__libinfo;" ;
99- output " }"
99+ output " }" ;
100100
101101sub output
102102{
Original file line number Diff line number Diff line change 1010 'target_name' : 'perfect' ,
1111 'type' : 'executable' ,
1212
13- 'conditions' :
13+ 'toolsets' : ['target' ,'host' ],
14+
15+ 'product_name' : 'perfect' ,
16+
17+ 'target_conditions' :
1418 [
1519 [
16- 'OS == "linux" or OS == "android "' ,
20+ '_toolset != "target "' ,
1721 {
18- 'toolsets ' : [ 'host' ] ,
22+ 'product_name ' : 'perfect->(_toolset)' ,
1923 },
2024 ],
2125 ],
3337 },
3438 },
3539
36- 'xcode_settings' :
37- {
38- 'conditions' :
39- [
40- [
41- 'OS == "mac" or OS == "ios"' ,
42- {
43- 'SDKROOT' : '<(host_sdk)' ,
44- 'ARCHS' : '<(host_arch)' ,
45- },
46- ],
47- [
48- # FIXME Force the perfect executable to be put into
49- # the target SDK's output directory, so that it
50- # appears in the PRODUCT_DIR when building against
51- # the target SDK
52- 'OS == "ios"' ,
53- {
54- 'SYMROOT' : '$(SOLUTION_DIR)/_build/ios/<(target_sdk)' ,
55- },
56- ],
57- ],
58- },
59-
6040 'direct_dependent_settings' :
6141 {
6242 'variables' :
6343 {
6444 'perfect_path' : '<(PRODUCT_DIR)/perfect<(EXECUTABLE_SUFFIX)' ,
6545 },
6646 },
47+
48+ 'conditions' :
49+ [
50+ [
51+ 'OS == "ios"' ,
52+ {
53+ 'direct_dependent_settings' :
54+ {
55+ 'variables' :
56+ {
57+ 'perfect_path' : '<(mac_tools_dir)/perfect-host' ,
58+ },
59+ },
60+ },
61+ ],
62+ ],
6763 },
6864 ],
6965}
You can’t perform that action at this time.
0 commit comments