diff options
Diffstat (limited to 'external/poky/meta/recipes-extended/newt')
-rw-r--r-- | external/poky/meta/recipes-extended/newt/files/0002-don-t-ignore-CFLAGS-when-building-snack.patch | 29 | ||||
-rw-r--r-- | external/poky/meta/recipes-extended/newt/files/fix_SHAREDDIR.patch | 37 | ||||
-rw-r--r-- | external/poky/meta/recipes-extended/newt/files/pie-flags.patch | 36 | ||||
-rw-r--r-- | external/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb | 28 | ||||
-rw-r--r-- | external/poky/meta/recipes-extended/newt/libnewt_0.52.21.bb (renamed from external/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb) | 22 |
5 files changed, 42 insertions, 110 deletions
diff --git a/external/poky/meta/recipes-extended/newt/files/0002-don-t-ignore-CFLAGS-when-building-snack.patch b/external/poky/meta/recipes-extended/newt/files/0002-don-t-ignore-CFLAGS-when-building-snack.patch new file mode 100644 index 00000000..ca235d51 --- /dev/null +++ b/external/poky/meta/recipes-extended/newt/files/0002-don-t-ignore-CFLAGS-when-building-snack.patch @@ -0,0 +1,29 @@ +From f60dc1063607ca1f201ba4cbda467d8af3f78f64 Mon Sep 17 00:00:00 2001 +From: Miroslav Lichvar <mlichvar@redhat.com> +Date: Tue, 1 Oct 2019 16:37:55 +0200 +Subject: [PATCH] don't ignore CFLAGS when building snack + +In addition to the flags returned by python-config --cflags, use the +user-specified CFLAGS when building the snack object. + +Upstream-Status: Backport from master +Signed-off-by: Joshua Watt <JPEWhacker@gmail.com> +--- + Makefile.in | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/Makefile.in b/Makefile.in +index be5f87b..6facd5e 100644 +--- a/Makefile.in ++++ b/Makefile.in +@@ -96,8 +96,8 @@ _snack.$(SOEXT): snack.c $(LIBNEWTSH) + PIFLAGS=`$$pyconfig --includes`; \ + PLDFLAGS=`$$pyconfig --ldflags`; \ + PLFLAGS=`$$pyconfig --libs`; \ +- echo $(CC) $(SHCFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ +- $(CC) $(SHCFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ ++ echo $(CC) $(SHCFLAGS) $(CFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ ++ $(CC) $(SHCFLAGS) $(CFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ + echo $(CC) --shared $$PLDFLAGS $$PLFLAGS $(LDFLAGS) -o $$ver/_snack.$(SOEXT) $$ver/snack.o -L. -lnewt $(LIBS); \ + $(CC) --shared $$PLDFLAGS $$PLFLAGS $(LDFLAGS) -o $$ver/_snack.$(SOEXT) $$ver/snack.o -L. -lnewt $(LIBS); \ + done || : diff --git a/external/poky/meta/recipes-extended/newt/files/fix_SHAREDDIR.patch b/external/poky/meta/recipes-extended/newt/files/fix_SHAREDDIR.patch deleted file mode 100644 index b0a1e8c1..00000000 --- a/external/poky/meta/recipes-extended/newt/files/fix_SHAREDDIR.patch +++ /dev/null @@ -1,37 +0,0 @@ -Upstream-Status: Pending - -Author: dexuan.cui@intel.com -Date: Fri Apr 15 16:17:39 CST 2011 - -The patch fixes a parallel-make issue: when generating $(SHAREDDIR)/%.o, we should -ensure the directory ${SHAREDDIR} exists. - -We need to push the patch to upstream. - -Signed-off-by: Dexuan Cui <dexuan.cui@intel.com> -Signed-off-by: Hongxu Jia <hongxu.jia@windriver.com> ---- - Makefile.in | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/Makefile.in b/Makefile.in ---- a/Makefile.in -+++ b/Makefile.in -@@ -128,12 +128,12 @@ $(SHAREDDIR): - - sharedlib: $(LIBNEWTSH) - --$(LIBNEWTSH): $(SHAREDDIR) $(SHAREDOBJS) -+$(LIBNEWTSH): $(SHAREDOBJS) - $(CC) -shared -o $(LIBNEWTSH) $(SHLIBFLAGS) $(SHAREDOBJS) $(LDFLAGS) $(LIBS) - ln -fs $(LIBNEWTSONAME) libnewt.$(SOEXT) - ln -fs $(LIBNEWTSH) $(LIBNEWTSONAME) - --$(SHAREDDIR)/%.o : %.c -+$(SHAREDDIR)/%.o : %.c $(SHAREDDIR) - $(CC) $(SHCFLAGS) -c $(CFLAGS) $(CPPFLAGS) -o $@ $< - - install: $(LIBNEWT) install-sh whiptail --- -1.8.1.2 - diff --git a/external/poky/meta/recipes-extended/newt/files/pie-flags.patch b/external/poky/meta/recipes-extended/newt/files/pie-flags.patch deleted file mode 100644 index 8883e26a..00000000 --- a/external/poky/meta/recipes-extended/newt/files/pie-flags.patch +++ /dev/null @@ -1,36 +0,0 @@ -specify -fPIC after CFLAGS so it can override the CFLAGS containing -pie and -fpie -this makes sure the objects that go into shared objects are compiled with -fPIC -and not with -fpie. We can not use -fpie on objects which will go into .so files -Fixes errors like - -| /mnt/oe/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/5.3.0/ld: shared/newt.o: relocation R_X86_64_PC32 against undefined symbol `SLtt_Screen_Rows@@SLANG2' can not be used when making a shared object; recompile with -fPIC -| /mnt/oe/build/tmp-glibc/sysroots/x86_64-linux/usr/libexec/x86_64-oe-linux/gcc/x86_64-oe-linux/5.3.0/ld: final link failed: Bad value -| collect2: error: ld returned 1 exit status -| make: *** [libnewt.so.0.52.18] Error 1 - -Signed-off-by: Khem Raj <raj.khem@gmail.com> -Upstream-Status: Pending -Index: newt-0.52.18/Makefile.in -=================================================================== ---- newt-0.52.18.orig/Makefile.in -+++ newt-0.52.18/Makefile.in -@@ -96,8 +96,8 @@ _snack.$(SOEXT): snack.c $(LIBNEWTSH) - PIFLAGS=`$$pyconfig --includes`; \ - PLDFLAGS=`$$pyconfig --ldflags`; \ - PLFLAGS=`$$pyconfig --libs`; \ -- echo $(CC) $(SHCFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ -- $(CC) $(SHCFLAGS) $(CPPFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ -+ echo $(CC) $(CPPFLAGS) $(SHCFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ -+ $(CC) $(CPPFLAGS) $(SHCFLAGS) $$PIFLAGS $$PCFLAGS -c -o $$ver/snack.o snack.c; \ - echo $(CC) --shared $$PLDFLAGS $$PLFLAGS $(LDFLAGS) -o $$ver/_snack.$(SOEXT) $$ver/snack.o -L. -lnewt $(LIBS); \ - $(CC) --shared $$PLDFLAGS $$PLFLAGS $(LDFLAGS) -o $$ver/_snack.$(SOEXT) $$ver/snack.o -L. -lnewt $(LIBS); \ - done || : -@@ -135,7 +135,7 @@ $(LIBNEWTSH): $(SHAREDOBJS) - ln -fs $(LIBNEWTSH) $(LIBNEWTSONAME) - - $(SHAREDDIR)/%.o : %.c $(SHAREDDIR) -- $(CC) $(SHCFLAGS) -c $(CFLAGS) $(CPPFLAGS) -o $@ $< -+ $(CC) -c $(CFLAGS) $(CPPFLAGS) $(SHCFLAGS) -o $@ $< - - install: $(LIBNEWT) install-sh whiptail - [ -d $(instroot)/$(bindir) ] || install -m 755 -d $(instroot)/$(bindir) diff --git a/external/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb b/external/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb deleted file mode 100644 index 433d184c..00000000 --- a/external/poky/meta/recipes-extended/newt/libnewt-python_0.52.20.bb +++ /dev/null @@ -1,28 +0,0 @@ -require recipes-extended/newt/libnewt_${PV}.bb - -SUMMARY .= " - python" -DEPENDS = "libnewt python3" -RDEPENDS_${PN} += "python3-core" - -inherit python3native python3-dir - -EXTRA_OECONF += "--with-python" -EXTRA_OEMAKE += "PYTHONVERS=${PYTHON_DIR}" - - -do_compile () { - VERSION="$(sed -n 's/^VERSION = //p' Makefile)" - oe_runmake _snack.so -} - -do_install () { - install -d ${D}${PYTHON_SITEPACKAGES_DIR} - install -m 0755 ${PYTHON_DIR}/_snack.so ${D}${PYTHON_SITEPACKAGES_DIR}/ - install -m 0644 snack.py ${D}${PYTHON_SITEPACKAGES_DIR}/ -} - -PACKAGES_remove = "whiptail" - -FILES_${PN} = "${PYTHON_SITEPACKAGES_DIR}/*" - -BBCLASSEXTEND = "native nativesdk" diff --git a/external/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb b/external/poky/meta/recipes-extended/newt/libnewt_0.52.21.bb index 264ef3b8..88b4cf4a 100644 --- a/external/poky/meta/recipes-extended/newt/libnewt_0.52.20.bb +++ b/external/poky/meta/recipes-extended/newt/libnewt_0.52.21.bb @@ -15,30 +15,34 @@ LICENSE = "LGPLv2" LIC_FILES_CHKSUM = "file://COPYING;md5=5f30f0716dfdd0d91eb439ebec522ec2" # slang needs to be >= 2.2 -DEPENDS = "slang popt" +DEPENDS = "slang popt python3" SRC_URI = "https://releases.pagure.org/newt/newt-${PV}.tar.gz \ - file://fix_SHAREDDIR.patch \ file://cross_ar.patch \ file://Makefile.in-Add-tinfo-library-to-the-linking-librari.patch \ - file://pie-flags.patch \ file://0001-detect-gold-as-GNU-linker-too.patch \ -" + file://0002-don-t-ignore-CFLAGS-when-building-snack.patch \ + " -SRC_URI[md5sum] = "70b288f821234593a8e7920e435b259b" -SRC_URI[sha256sum] = "8d66ba6beffc3f786d4ccfee9d2b43d93484680ef8db9397a4fb70b5adbb6dbc" +SRC_URI[md5sum] = "a0a5fd6b53bb167a65e15996b249ebb5" +SRC_URI[sha256sum] = "265eb46b55d7eaeb887fca7a1d51fe115658882dfe148164b6c49fccac5abb31" S = "${WORKDIR}/newt-${PV}" -EXTRA_OECONF = "--without-tcl --without-python" +inherit autotools-brokensep python3native python3-dir -inherit autotools-brokensep +EXTRA_OECONF = "--without-tcl --with-python" + +EXTRA_OEMAKE += "PYTHONVERS=${PYTHON_DIR}" CLEANBROKEN = "1" export CPPFLAGS -PACKAGES_prepend = "whiptail " +PACKAGES_prepend = "whiptail ${PN}-python " + +RDEPENDS_${PN}-python += "python3-core" +FILES_${PN}-python = "${PYTHON_SITEPACKAGES_DIR}/*" do_configure_prepend() { sh autogen.sh |