lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20180329004805.7278-2-labbott@redhat.com>
Date:   Wed, 28 Mar 2018 17:48:03 -0700
From:   Laura Abbott <labbott@...hat.com>
To:     Masahiro Yamada <yamada.masahiro@...ionext.com>,
        Michal Marek <michal.lkml@...kovi.net>
Cc:     Laura Abbott <labbott@...hat.com>, linux-kbuild@...r.kernel.org,
        linux-kernel@...r.kernel.org, Josh Poimboeuf <jpoimboe@...hat.com>
Subject: [PATCH 1/3] kbuild: Support HOSTLDFLAGS


In addition to HOSTCFLAGS, there's HOSTLDFLAGS. Ensure these get passed to
calls to build host binaries.

Signed-off-by: Laura Abbott <labbott@...hat.com>
---
 scripts/Makefile.host      | 6 +++---
 tools/build/Makefile.build | 2 +-
 2 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/scripts/Makefile.host b/scripts/Makefile.host
index e6dc6ae2d7c4..a3a0e2282a56 100644
--- a/scripts/Makefile.host
+++ b/scripts/Makefile.host
@@ -84,7 +84,7 @@ hostcxx_flags  = -Wp,-MD,$(depfile) $(__hostcxx_flags)
 # Create executable from a single .c file
 # host-csingle -> Executable
 quiet_cmd_host-csingle 	= HOSTCC  $@
-      cmd_host-csingle	= $(HOSTCC) $(hostc_flags) -o $@ $< \
+      cmd_host-csingle	= $(HOSTCC) $(HOSTLDFLAGS) $(hostc_flags) -o $@ $< \
 	  	$(HOST_LOADLIBES) $(HOSTLOADLIBES_$(@F))
 $(host-csingle): $(obj)/%: $(src)/%.c FORCE
 	$(call if_changed_dep,host-csingle)
@@ -102,7 +102,7 @@ $(call multi_depend, $(host-cmulti), , -objs)
 # Create .o file from a single .c file
 # host-cobjs -> .o
 quiet_cmd_host-cobjs	= HOSTCC  $@
-      cmd_host-cobjs	= $(HOSTCC) $(hostc_flags) -c -o $@ $<
+      cmd_host-cobjs	= $(HOSTCC) $(HOSTLDFLAGS) $(hostc_flags) -c -o $@ $<
 $(host-cobjs): $(obj)/%.o: $(src)/%.c FORCE
 	$(call if_changed_dep,host-cobjs)
 
@@ -126,7 +126,7 @@ $(host-cxxobjs): $(obj)/%.o: $(src)/%.cc FORCE
 # Compile .c file, create position independent .o file
 # host-cshobjs -> .o
 quiet_cmd_host-cshobjs	= HOSTCC  -fPIC $@
-      cmd_host-cshobjs	= $(HOSTCC) $(hostc_flags) -fPIC -c -o $@ $<
+      cmd_host-cshobjs	= $(HOSTCC) $(HOSTLDFLAGS) $(hostc_flags) -fPIC -c -o $@ $<
 $(host-cshobjs): $(obj)/%.o: $(src)/%.c FORCE
 	$(call if_changed_dep,host-cshobjs)
 
diff --git a/tools/build/Makefile.build b/tools/build/Makefile.build
index cd72016c3cfa..cab55f0d90e1 100644
--- a/tools/build/Makefile.build
+++ b/tools/build/Makefile.build
@@ -64,7 +64,7 @@ quiet_cmd_cc_o_c = CC       $@
       cmd_cc_o_c = $(CC) $(c_flags) -c -o $@ $<
 
 quiet_cmd_host_cc_o_c = HOSTCC   $@
-      cmd_host_cc_o_c = $(HOSTCC) $(host_c_flags) -c -o $@ $<
+      cmd_host_cc_o_c = $(HOSTCC) $(HOSTLDFLAGS) $(host_c_flags) -c -o $@ $<
 
 quiet_cmd_cxx_o_c = CXX      $@
       cmd_cxx_o_c = $(CXX) $(cxx_flags) -c -o $@ $<
-- 
2.16.2

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ