OLD | NEW |
1 # | 1 # |
2 # Copyright 2013 the V8 project authors. All rights reserved. | 2 # Copyright 2013 the V8 project authors. All rights reserved. |
3 # Redistribution and use in source and binary forms, with or without | 3 # Redistribution and use in source and binary forms, with or without |
4 # modification, are permitted provided that the following conditions are | 4 # modification, are permitted provided that the following conditions are |
5 # met: | 5 # met: |
6 # | 6 # |
7 # * Redistributions of source code must retain the above copyright | 7 # * Redistributions of source code must retain the above copyright |
8 # notice, this list of conditions and the following disclaimer. | 8 # notice, this list of conditions and the following disclaimer. |
9 # * Redistributions in binary form must reproduce the above | 9 # * Redistributions in binary form must reproduce the above |
10 # copyright notice, this list of conditions and the following | 10 # copyright notice, this list of conditions and the following |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
70 ifeq ($(wildcard $(NACL_TOOLCHAIN)),) | 70 ifeq ($(wildcard $(NACL_TOOLCHAIN)),) |
71 $(error Cannot find Native Client toolchain in "${NACL_TOOLCHAIN}") | 71 $(error Cannot find Native Client toolchain in "${NACL_TOOLCHAIN}") |
72 endif | 72 endif |
73 | 73 |
74 # For mksnapshot host generation. | 74 # For mksnapshot host generation. |
75 GYPENV += host_os=${HOST_OS} | 75 GYPENV += host_os=${HOST_OS} |
76 | 76 |
77 # ICU doesn't support NaCl. | 77 # ICU doesn't support NaCl. |
78 GYPENV += v8_enable_i18n_support=0 | 78 GYPENV += v8_enable_i18n_support=0 |
79 | 79 |
| 80 # Disable strict aliasing - v8 code often relies on undefined behavior of C++. |
| 81 GYPENV += v8_no_strict_aliasing=1 |
| 82 |
80 NACL_MAKEFILES = $(addprefix $(OUTDIR)/Makefile.,$(NACL_BUILDS)) | 83 NACL_MAKEFILES = $(addprefix $(OUTDIR)/Makefile.,$(NACL_BUILDS)) |
81 .SECONDEXPANSION: | 84 .SECONDEXPANSION: |
82 # For some reason the $$(basename $$@) expansion didn't work here... | 85 # For some reason the $$(basename $$@) expansion didn't work here... |
83 $(NACL_BUILDS): $(NACL_MAKEFILES) | 86 $(NACL_BUILDS): $(NACL_MAKEFILES) |
84 @$(MAKE) -C "$(OUTDIR)" -f Makefile.$@ \ | 87 @$(MAKE) -C "$(OUTDIR)" -f Makefile.$@ \ |
85 CXX=${NACL_CXX} \ | 88 CXX=${NACL_CXX} \ |
86 LINK=${NACL_LINK} \ | 89 LINK=${NACL_LINK} \ |
87 BUILDTYPE=$(shell echo $(subst .,,$(suffix $@)) | \ | 90 BUILDTYPE=$(shell echo $(subst .,,$(suffix $@)) | \ |
88 python -c "print raw_input().capitalize()") \ | 91 python -c "print raw_input().capitalize()") \ |
89 builddir="$(shell pwd)/$(OUTDIR)/$@" | 92 builddir="$(shell pwd)/$(OUTDIR)/$@" |
90 | 93 |
91 # NACL GYP file generation targets. | 94 # NACL GYP file generation targets. |
92 $(NACL_MAKEFILES): | 95 $(NACL_MAKEFILES): |
93 GYP_GENERATORS=make \ | 96 GYP_GENERATORS=make \ |
94 GYP_DEFINES="${GYPENV}" \ | 97 GYP_DEFINES="${GYPENV}" \ |
95 CC=${NACL_CC} \ | 98 CC=${NACL_CC} \ |
96 CXX=${NACL_CXX} \ | 99 CXX=${NACL_CXX} \ |
97 PYTHONPATH="$(shell pwd)/tools/generate_shim_headers:$(PYTHONPATH)" \ | 100 PYTHONPATH="$(shell pwd)/tools/generate_shim_headers:$(PYTHONPATH)" \ |
98 build/gyp/gyp --generator-output="${OUTDIR}" build/all.gyp \ | 101 build/gyp/gyp --generator-output="${OUTDIR}" build/all.gyp \ |
99 -Ibuild/standalone.gypi --depth=. \ | 102 -Ibuild/standalone.gypi --depth=. \ |
100 -S$(suffix $(basename $@))$(suffix $@) $(GYPFLAGS) \ | 103 -S$(suffix $(basename $@))$(suffix $@) $(GYPFLAGS) \ |
101 -Dwno_array_bounds=-Wno-array-bounds | 104 -Dwno_array_bounds=-Wno-array-bounds |
OLD | NEW |