meson: prepare to use different linkers
authorAndre Heider <a.heider@gmail.com>
Fri, 27 Jan 2023 15:33:25 +0000 (16:33 +0100)
committerChristian Marangi <ansuelsmth@gmail.com>
Tue, 4 Jul 2023 18:25:40 +0000 (20:25 +0200)
This sets the default linker for cross compilation.

No functional change intended.

Signed-off-by: Andre Heider <a.heider@gmail.com>
include/meson.mk
tools/meson/Makefile
tools/meson/files/openwrt-cross.txt.in

index 7d67dcf298b3e843049815878b53d69a67dcf9c0..74c9d3dd7fa25fd1273085a97422d2841850e6ae 100644 (file)
@@ -78,6 +78,7 @@ define Meson/CreateCrossFile
        $(STAGING_DIR_HOST)/bin/sed \
                -e "s|@CC@|$(foreach BIN,$(TARGET_CC),'$(BIN)',)|" \
                -e "s|@CXX@|$(foreach BIN,$(TARGET_CXX),'$(BIN)',)|" \
+               -e "s|@LD@|$(foreach FLAG,$(TARGET_LINKER),'$(FLAG)',)|" \
                -e "s|@AR@|$(TARGET_AR)|" \
                -e "s|@STRIP@|$(TARGET_CROSS)strip|" \
                -e "s|@NM@|$(TARGET_NM)|" \
index b115e0802b529a261900305faa154df100dc4554..f957bfb49f035b57d774a691f7aa60a8557f0cee 100644 (file)
@@ -2,6 +2,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=meson
 PKG_VERSION:=1.1.1
+PKG_RELEASE:=2
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=https://github.com/mesonbuild/meson/releases/download/$(PKG_VERSION)
index ec4b027f1b783b80d3ed9cc8f543c5eef4bdd7ce..ba119150691820c1f1432c7293d132e57a394adf 100644 (file)
@@ -1,6 +1,8 @@
 [binaries]
 c = [@CC@]
+c_ld = [@LD@]
 cpp = [@CXX@]
+cpp_ld = [@LD@]
 ar = '@AR@'
 strip = '@STRIP@'
 nm = '@NM@'