Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(145)

Side by Side Diff: native_client_sdk/src/tools/nacl_gcc.mk

Issue 176923017: [NaCl SDK] Compile for naclio for Bionic (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix bug in h_error Created 6 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « native_client_sdk/src/tools/common.mk ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 # Use of this source code is governed by a BSD-style license that can be 2 # Use of this source code is governed by a BSD-style license that can be
3 # found in the LICENSE file. 3 # found in the LICENSE file.
4 4
5 # 5 #
6 # GNU Make based build file. For details on GNU Make see: 6 # GNU Make based build file. For details on GNU Make see:
7 # http://www.gnu.org/software/make/manual/make.html 7 # http://www.gnu.org/software/make/manual/make.html
8 # 8 #
9 9
10 # 10 #
(...skipping 25 matching lines...) Expand all
36 ARM_LIB := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=ar) 36 ARM_LIB := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=ar)
37 ARM_STRIP := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=strip) 37 ARM_STRIP := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=strip)
38 ARM_NM := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=nm) 38 ARM_NM := $(shell $(NACL_CONFIG) -t $(TOOLCHAIN) -a arm --tool=nm)
39 endif 39 endif
40 40
41 NCVAL ?= python $(NACL_SDK_ROOT)/tools/ncval.py 41 NCVAL ?= python $(NACL_SDK_ROOT)/tools/ncval.py
42 42
43 # Architecture-specific flags 43 # Architecture-specific flags
44 X86_32_CFLAGS ?= 44 X86_32_CFLAGS ?=
45 X86_64_CFLAGS ?= 45 X86_64_CFLAGS ?=
46 ARM_CFLAGS ?=
47
48 X86_32_CXXFLAGS ?= 46 X86_32_CXXFLAGS ?=
49 X86_64_CXXFLAGS ?= 47 X86_64_CXXFLAGS ?=
48
49 # Use DWARF v3 which is more commonly available when debugging
50 ifeq ($(CONFIG),Debug)
51 ARM_CFLAGS ?= -gdwarf-3
52 ARM_CXXFLAGS ?= -gdwarf-3
53 else
54 ARM_CFLAGS ?=
50 ARM_CXXFLAGS ?= 55 ARM_CXXFLAGS ?=
56 endif
51 57
52 X86_32_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_x86_32.map 58 X86_32_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_x86_32.map
53 X86_64_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_x86_64.map 59 X86_64_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_x86_64.map
54 ARM_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_arm.map 60 ARM_LDFLAGS ?= -Wl,-Map,$(OUTDIR)/$(TARGET)_arm.map
55 61
56 LDFLAGS_SHARED = -shared 62 LDFLAGS_SHARED = -shared
57 63
58 # 64 #
59 # Compile Macro 65 # Compile Macro
60 # 66 #
(...skipping 261 matching lines...) Expand 10 before | Expand all | Expand 10 after
322 ifneq (,$(findstring x86_64,$(ARCHES))) 328 ifneq (,$(findstring x86_64,$(ARCHES)))
323 all: $(OUTDIR)/$(1)_x86_64.nexe 329 all: $(OUTDIR)/$(1)_x86_64.nexe
324 $(OUTDIR)/$(1)_x86_64.nexe: $(foreach src,$(2),$(call SRC_TO_OBJ,$(src),_x86_64) ) $(foreach dep,$(4),$(STAMPDIR)/$(dep).stamp) 330 $(OUTDIR)/$(1)_x86_64.nexe: $(foreach src,$(2),$(call SRC_TO_OBJ,$(src),_x86_64) ) $(foreach dep,$(4),$(STAMPDIR)/$(dep).stamp)
325 $(call LOG,LINK,$$@,$(X86_64_LINK) -o $$@ $$(filter %.o,$$^) $(NACL_LDFL AGS) $(X86_64_LDFLAGS) $(foreach path,$(6),-L$(path)/$(TOOLCHAIN)_x86_64/$(CONFI G)) $(foreach lib,$(3),-l$(lib)) $(5)) 331 $(call LOG,LINK,$$@,$(X86_64_LINK) -o $$@ $$(filter %.o,$$^) $(NACL_LDFL AGS) $(X86_64_LDFLAGS) $(foreach path,$(6),-L$(path)/$(TOOLCHAIN)_x86_64/$(CONFI G)) $(foreach lib,$(3),-l$(lib)) $(5))
326 $(call LOG,VALIDATE,$$@,$(NCVAL) $$@) 332 $(call LOG,VALIDATE,$$@,$(NCVAL) $$@)
327 endif 333 endif
328 334
329 ifneq (,$(findstring arm,$(ARCHES))) 335 ifneq (,$(findstring arm,$(ARCHES)))
330 all: $(OUTDIR)/$(1)_arm.nexe 336 all: $(OUTDIR)/$(1)_arm.nexe
331 $(OUTDIR)/$(1)_arm.nexe: $(foreach src,$(2),$(call SRC_TO_OBJ,$(src),_arm)) $(fo reach dep,$(4),$(STAMPDIR)/$(dep).stamp) 337 $(OUTDIR)/$(1)_arm.nexe: $(foreach src,$(2),$(call SRC_TO_OBJ,$(src),_arm)) $(fo reach dep,$(4),$(STAMPDIR)/$(dep).stamp)
332 » $(call LOG,LINK,$$@,$(ARM_LINK) -o $$@ $$(filter %.o,$$^) $(NACL_LDFLAGS ) $(ARM_LDFLAGS) $(foreach path,$(6),-L$(path)/$(TOOLCHAIN)_arm/$(CONFIG)) $(for each lib,$(3),-l$(lib)) $(5)) 338 » $(call LOG,LINK,$$@,$(ARM_LINK) -static -o $$@ $$(filter %.o,$$^) $(NACL _LDFLAGS) $(ARM_LDFLAGS) $(foreach path,$(6),-L$(path)/$(TOOLCHAIN)_arm/$(CONFIG )) $(foreach lib,$(3),-l$(lib)) $(5))
333 $(call LOG,VALIDATE,$$@,$(NCVAL) $$@) 339 $(call LOG,VALIDATE,$$@,$(NCVAL) $$@)
334 endif 340 endif
335 endef 341 endef
336 342
337 343
338 # 344 #
339 # Generalized Link Macro 345 # Generalized Link Macro
340 # 346 #
341 # $1 = Target Name 347 # $1 = Target Name
342 # $2 = List of Sources 348 # $2 = List of Sources
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
491 $(error Cannot run in sel_ldr unless $$NACL_ARCH is set) 497 $(error Cannot run in sel_ldr unless $$NACL_ARCH is set)
492 endif 498 endif
493 $(SEL_LDR_PATH) $(SEL_LDR_ARGS) $(OUTDIR)/$(TARGET)_$(NACL_ARCH).nexe -- $(EXE_ARGS) 499 $(SEL_LDR_PATH) $(SEL_LDR_ARGS) $(OUTDIR)/$(TARGET)_$(NACL_ARCH).nexe -- $(EXE_ARGS)
494 500
495 debug: all 501 debug: all
496 ifndef NACL_ARCH 502 ifndef NACL_ARCH
497 $(error Cannot run in sel_ldr unless $$NACL_ARCH is set) 503 $(error Cannot run in sel_ldr unless $$NACL_ARCH is set)
498 endif 504 endif
499 $(SEL_LDR_PATH) -d $(SEL_LDR_ARGS) $(OUTDIR)/$(TARGET)_$(NACL_ARCH).nexe -- $(EXE_ARGS) 505 $(SEL_LDR_PATH) -d $(SEL_LDR_ARGS) $(OUTDIR)/$(TARGET)_$(NACL_ARCH).nexe -- $(EXE_ARGS)
500 endif 506 endif
OLDNEW
« no previous file with comments | « native_client_sdk/src/tools/common.mk ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698