mirror of
https://github.com/checkpoint-restore/criu.git
synced 2026-01-23 02:14:37 +00:00
build system: make CC/LD derive from HOSTCC/HOSTLD
1. Move HOSTCC/HOSTLD to nmk (note there are rules in nmk that make use of these variables already) 2. Make CC/LD derive from HOSTCC/HOSTLD Note that one can still change anything from the command line. travis-ci: success for build system: make CC/LD derive from HOSTCC/HOSTLD Cc: Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by: Kir Kolyshkin <kir@openvz.org> Acked-by: Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@virtuozzo.com>
This commit is contained in:
parent
19f7f130ae
commit
67388c2455
2 changed files with 5 additions and 9 deletions
6
Makefile
6
Makefile
|
|
@ -6,12 +6,6 @@ export __nmk_dir
|
|||
include $(__nmk_dir)include.mk
|
||||
include $(__nmk_dir)macro.mk
|
||||
|
||||
#
|
||||
# To build host helpers.
|
||||
HOSTCC ?= gcc
|
||||
HOSTLD ?= ld
|
||||
export HOSTCC HOSTLD
|
||||
|
||||
CFLAGS += $(USERCFLAGS)
|
||||
export CFLAGS
|
||||
|
||||
|
|
|
|||
|
|
@ -3,8 +3,10 @@ ifndef ____nmk_defined__tools
|
|||
#
|
||||
# System tools shorthands
|
||||
RM := rm -f
|
||||
LD := $(CROSS_COMPILE)ld
|
||||
CC := $(CROSS_COMPILE)gcc
|
||||
HOSTLD ?= ld
|
||||
LD := $(CROSS_COMPILE)$(HOSTLD)
|
||||
HOSTCC ?= gcc
|
||||
CC := $(CROSS_COMPILE)$(HOSTCC)
|
||||
CPP := $(CC) -E
|
||||
AS := $(CROSS_COMPILE)as
|
||||
AR := $(CROSS_COMPILE)ar
|
||||
|
|
@ -25,7 +27,7 @@ CSCOPE := cscope
|
|||
ETAGS := etags
|
||||
CTAGS := ctags
|
||||
|
||||
export RM LD CC CPP AS AR STRIP OBJCOPY OBJDUMP
|
||||
export RM HOSTLD LD HOSTCC CC CPP AS AR STRIP OBJCOPY OBJDUMP
|
||||
export NM SH MAKE MKDIR AWK PERL PYTHON SH CSCOPE
|
||||
|
||||
#
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue