summaryrefslogtreecommitdiff
path: root/packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch
diff options
context:
space:
mode:
Diffstat (limited to 'packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch')
-rw-r--r--packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch182
1 files changed, 182 insertions, 0 deletions
diff --git a/packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch b/packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch
new file mode 100644
index 0000000..b4bf18b
--- /dev/null
+++ b/packages/sys-kernel/linux-image-redcore-lts/files/0001-pkg-config.patch
@@ -0,0 +1,182 @@
+diff -Nur a/scripts/kconfig/lxdialog/check-lxdialog.sh b/scripts/kconfig/lxdialog/check-lxdialog.sh
+--- a/scripts/kconfig/lxdialog/check-lxdialog.sh 2018-08-18 09:48:00.000000000 +0100
++++ b/scripts/kconfig/lxdialog/check-lxdialog.sh 2018-10-14 21:29:13.467708635 +0100
+@@ -5,8 +5,8 @@
+ # What library to link
+ ldflags()
+ {
+- pkg-config --libs ncursesw 2>/dev/null && exit
+- pkg-config --libs ncurses 2>/dev/null && exit
++ x86_64-pc-linux-gnu-pkg-config --libs ncursesw 2>/dev/null && exit
++ x86_64-pc-linux-gnu-pkg-config --libs ncurses 2>/dev/null && exit
+ for ext in so a dll.a dylib ; do
+ for lib in ncursesw ncurses curses ; do
+ $cc -print-file-name=lib${lib}.${ext} | grep -q /
+@@ -22,9 +22,9 @@
+ # Where is ncurses.h?
+ ccflags()
+ {
+- if pkg-config --cflags ncursesw 2>/dev/null; then
++ if x86_64-pc-linux-gnu-pkg-config --cflags ncursesw 2>/dev/null; then
+ echo '-DCURSES_LOC="<ncurses.h>" -DNCURSES_WIDECHAR=1'
+- elif pkg-config --cflags ncurses 2>/dev/null; then
++ elif x86_64-pc-linux-gnu-pkg-config --cflags ncurses 2>/dev/null; then
+ echo '-DCURSES_LOC="<ncurses.h>"'
+ elif [ -f /usr/include/ncursesw/curses.h ]; then
+ echo '-I/usr/include/ncursesw -DCURSES_LOC="<curses.h>"'
+diff -Nur a/scripts/kconfig/Makefile b/scripts/kconfig/Makefile
+--- a/scripts/kconfig/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/scripts/kconfig/Makefile 2018-10-14 21:29:24.686077418 +0100
+@@ -216,15 +216,15 @@
+ HOSTLOADLIBES_qconf = $(KC_QT_LIBS)
+ HOSTCXXFLAGS_qconf.o = $(KC_QT_CFLAGS)
+
+-HOSTLOADLIBES_gconf = `pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0`
+-HOSTCFLAGS_gconf.o = `pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \
++HOSTLOADLIBES_gconf = `x86_64-pc-linux-gnu-pkg-config --libs gtk+-2.0 gmodule-2.0 libglade-2.0`
++HOSTCFLAGS_gconf.o = `x86_64-pc-linux-gnu-pkg-config --cflags gtk+-2.0 gmodule-2.0 libglade-2.0` \
+ -Wno-missing-prototypes
+
+ HOSTLOADLIBES_mconf = $(shell $(CONFIG_SHELL) $(check-lxdialog) -ldflags $(HOSTCC))
+
+ HOSTLOADLIBES_nconf = $(shell \
+- pkg-config --libs menuw panelw ncursesw 2>/dev/null \
+- || pkg-config --libs menu panel ncurses 2>/dev/null \
++ x86_64-pc-linux-gnu-pkg-config --libs menuw panelw ncursesw 2>/dev/null \
++ || x86_64-pc-linux-gnu-pkg-config --libs menu panel ncurses 2>/dev/null \
+ || echo "-lmenu -lpanel -lncurses" )
+ $(obj)/qconf.o: $(obj)/.tmp_qtcheck
+
+@@ -235,17 +235,17 @@
+ # Qt needs some extra effort...
+ $(obj)/.tmp_qtcheck:
+ @set -e; $(kecho) " CHECK qt"; \
+- if pkg-config --exists Qt5Core; then \
+- cflags="-std=c++11 -fPIC `pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets`"; \
+- libs=`pkg-config --libs Qt5Core Qt5Gui Qt5Widgets`; \
+- moc=`pkg-config --variable=host_bins Qt5Core`/moc; \
+- elif pkg-config --exists QtCore; then \
+- cflags=`pkg-config --cflags QtCore QtGui`; \
+- libs=`pkg-config --libs QtCore QtGui`; \
+- moc=`pkg-config --variable=moc_location QtCore`; \
++ if x86_64-pc-linux-gnu-pkg-config --exists Qt5Core; then \
++ cflags="-std=c++11 -fPIC `x86_64-pc-linux-gnu-pkg-config --cflags Qt5Core Qt5Gui Qt5Widgets`"; \
++ libs=`x86_64-pc-linux-gnu-pkg-config --libs Qt5Core Qt5Gui Qt5Widgets`; \
++ moc=`x86_64-pc-linux-gnu-pkg-config --variable=host_bins Qt5Core`/moc; \
++ elif x86_64-pc-linux-gnu-pkg-config --exists QtCore; then \
++ cflags=`x86_64-pc-linux-gnu-pkg-config --cflags QtCore QtGui`; \
++ libs=`x86_64-pc-linux-gnu-pkg-config --libs QtCore QtGui`; \
++ moc=`x86_64-pc-linux-gnu-pkg-config --variable=moc_location QtCore`; \
+ else \
+ echo >&2 "*"; \
+- echo >&2 "* Could not find Qt via pkg-config."; \
++ echo >&2 "* Could not find Qt via x86_64-pc-linux-gnu-pkg-config."; \
+ echo >&2 "* Please install either Qt 4.8 or 5.x. and make sure it's in PKG_CONFIG_PATH"; \
+ echo >&2 "*"; \
+ exit 1; \
+@@ -262,8 +262,8 @@
+
+ # GTK+ needs some extra effort, too...
+ $(obj)/.tmp_gtkcheck:
+- @if `pkg-config --exists gtk+-2.0 gmodule-2.0 libglade-2.0`; then \
+- if `pkg-config --atleast-version=2.0.0 gtk+-2.0`; then \
++ @if `x86_64-pc-linux-gnu-pkg-config --exists gtk+-2.0 gmodule-2.0 libglade-2.0`; then \
++ if `x86_64-pc-linux-gnu-pkg-config --atleast-version=2.0.0 gtk+-2.0`; then \
+ touch $@; \
+ else \
+ echo >&2 "*"; \
+diff -Nur a/tools/build/feature/Makefile b/tools/build/feature/Makefile
+--- a/tools/build/feature/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/build/feature/Makefile 2018-10-14 21:29:33.110354352 +0100
+@@ -57,7 +57,7 @@
+
+ CC ?= $(CROSS_COMPILE)gcc
+ CXX ?= $(CROSS_COMPILE)g++
+-PKG_CONFIG ?= $(CROSS_COMPILE)pkg-config
++PKG_CONFIG ?= $(CROSS_COMPILE)x86_64-pc-linux-gnu-pkg-config
+ LLVM_CONFIG ?= llvm-config
+
+ all: $(FILES)
+diff -Nur a/tools/perf/Makefile.perf b/tools/perf/Makefile.perf
+--- a/tools/perf/Makefile.perf 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/perf/Makefile.perf 2018-10-14 21:30:34.871384703 +0100
+@@ -156,7 +156,7 @@
+ HOSTLD ?= ld
+ HOSTAR ?= ar
+
+-PKG_CONFIG = $(CROSS_COMPILE)pkg-config
++PKG_CONFIG = $(CROSS_COMPILE)x86_64-pc-linux-gnu-pkg-config
+ LLVM_CONFIG ?= llvm-config
+
+ RM = rm -f
+diff -Nur a/tools/testing/selftests/memfd/Makefile b/tools/testing/selftests/memfd/Makefile
+--- a/tools/testing/selftests/memfd/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/testing/selftests/memfd/Makefile 2018-10-14 21:30:25.358071953 +0100
+@@ -8,8 +8,8 @@
+ TEST_FILES := run_fuse_test.sh
+ TEST_GEN_FILES := memfd_test fuse_mnt fuse_test
+
+-fuse_mnt.o: CFLAGS += $(shell pkg-config fuse --cflags)
++fuse_mnt.o: CFLAGS += $(shell x86_64-pc-linux-gnu-pkg-config fuse --cflags)
+
+ include ../lib.mk
+
+-$(OUTPUT)/fuse_mnt: LDLIBS += $(shell pkg-config fuse --libs)
++$(OUTPUT)/fuse_mnt: LDLIBS += $(shell x86_64-pc-linux-gnu-pkg-config fuse --libs)
+diff -Nur a/tools/thermal/tmon/Makefile b/tools/thermal/tmon/Makefile
+--- a/tools/thermal/tmon/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/thermal/tmon/Makefile 2018-10-14 21:30:14.317709004 +0100
+@@ -19,12 +19,12 @@
+ endif
+
+ TMON_LIBS=-lm -lpthread
+-TMON_LIBS += $(shell pkg-config --libs $(STATIC) panelw ncursesw 2> /dev/null || \
+- pkg-config --libs $(STATIC) panel ncurses 2> /dev/null || \
++TMON_LIBS += $(shell x86_64-pc-linux-gnu-pkg-config --libs $(STATIC) panelw ncursesw 2> /dev/null || \
++ x86_64-pc-linux-gnu-pkg-config --libs $(STATIC) panel ncurses 2> /dev/null || \
+ echo -lpanel -lncurses)
+
+-CFLAGS += $(shell pkg-config --cflags $(STATIC) panelw ncursesw 2> /dev/null || \
+- pkg-config --cflags $(STATIC) panel ncurses 2> /dev/null)
++CFLAGS += $(shell x86_64-pc-linux-gnu-pkg-config --cflags $(STATIC) panelw ncursesw 2> /dev/null || \
++ x86_64-pc-linux-gnu-pkg-config --cflags $(STATIC) panel ncurses 2> /dev/null)
+
+ OBJS = tmon.o tui.o sysfs.o pid.o
+ OBJS +=
+diff -Nur a/tools/usb/ffs-aio-example/multibuff/host_app/Makefile b/tools/usb/ffs-aio-example/multibuff/host_app/Makefile
+--- a/tools/usb/ffs-aio-example/multibuff/host_app/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/usb/ffs-aio-example/multibuff/host_app/Makefile 2018-10-14 21:29:48.324854509 +0100
+@@ -1,7 +1,7 @@
+ # SPDX-License-Identifier: GPL-2.0
+ CC = gcc
+-LIBUSB_CFLAGS = $(shell pkg-config --cflags libusb-1.0)
+-LIBUSB_LIBS = $(shell pkg-config --libs libusb-1.0)
++LIBUSB_CFLAGS = $(shell x86_64-pc-linux-gnu-pkg-config --cflags libusb-1.0)
++LIBUSB_LIBS = $(shell x86_64-pc-linux-gnu-pkg-config --libs libusb-1.0)
+ WARNINGS = -Wall -Wextra
+ CFLAGS = $(LIBUSB_CFLAGS) $(WARNINGS)
+ LDFLAGS = $(LIBUSB_LIBS)
+diff -Nur a/tools/usb/ffs-aio-example/simple/host_app/Makefile b/tools/usb/ffs-aio-example/simple/host_app/Makefile
+--- a/tools/usb/ffs-aio-example/simple/host_app/Makefile 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/usb/ffs-aio-example/simple/host_app/Makefile 2018-10-14 21:29:55.668095911 +0100
+@@ -1,6 +1,6 @@
+ CC = gcc
+-LIBUSB_CFLAGS = $(shell pkg-config --cflags libusb-1.0)
+-LIBUSB_LIBS = $(shell pkg-config --libs libusb-1.0)
++LIBUSB_CFLAGS = $(shell x86_64-pc-linux-gnu-pkg-config --cflags libusb-1.0)
++LIBUSB_LIBS = $(shell x86_64-pc-linux-gnu-pkg-config --libs libusb-1.0)
+ WARNINGS = -Wall -Wextra
+ CFLAGS = $(LIBUSB_CFLAGS) $(WARNINGS)
+ LDFLAGS = $(LIBUSB_LIBS)
+diff -Nur a/tools/usb/usbip/README b/tools/usb/usbip/README
+--- a/tools/usb/usbip/README 2018-08-18 09:48:00.000000000 +0100
++++ b/tools/usb/usbip/README 2018-10-14 21:30:07.344479763 +0100
+@@ -40,7 +40,7 @@
+
+ - gcc >= 4.0
+
+- - libtool, automake >= 1.9, autoconf >= 2.5.0, pkg-config
++ - libtool, automake >= 1.9, autoconf >= 2.5.0, x86_64-pc-linux-gnu-pkg-config
+
+ [Optional]
+ - hwdata