Message ID | 20241030225457.1522289-1-raj.khem@gmail.com |
---|---|
State | New |
Headers | show |
Series | ppp: Add pam and openssl via packageconfig | expand |
On Wed, 30 Oct 2024 at 16:55, Khem Raj via lists.openembedded.org <raj.khem=gmail.com@lists.openembedded.org> wrote: > > Explicitly enable pam support, otherwise it goes into > detection mode and ends up poking at build host > > Turn openssl into packageconfig as well > > cc1: warning: include location "/usr/include" is unsafe for cross-compilation [-Wpoison-system-directories] > conftest.c: In function 'main': > conftest.c:68:1: warning: argument 1 null where non-null expected [-Wnonnull] > 68 | pam_authenticate(NULL, 0); > | ^~~~~~~~~~~~~~~~ > In file included from conftest.c:63: > /usr/include/security/pam_appl.h:38:1: note: in a call to function 'pam_authenticate' declared 'nonnull' > 38 | pam_authenticate(pam_handle_t *pamh, int flags); > | ^~~~~~~~~~~~~~~~ > > Signed-off-by: Khem Raj <raj.khem@gmail.com> > --- > meta/recipes-connectivity/ppp/ppp_2.5.1.bb | 6 ++++-- > 1 file changed, 4 insertions(+), 2 deletions(-) > > diff --git a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > index 5b8c49ca850..2b917905b24 100644 > --- a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > +++ b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > @@ -4,7 +4,7 @@ the Point-to-Point Protocol (PPP) on Linux and Solaris systems." > SECTION = "console/network" > HOMEPAGE = "http://samba.org/ppp/" > BUGTRACKER = "http://ppp.samba.org/cgi-bin/ppp-bugs" > -DEPENDS = "libpcap openssl virtual/crypt" > +DEPENDS = "libpcap virtual/crypt" > LICENSE = "BSD-3-Clause & BSD-3-Clause-Attribution & GPL-2.0-or-later & LGPL-2.0-or-later & PD & RSA-MD & MIT" > LIC_FILES_CHKSUM = "file://pppd/ccp.c;beginline=1;endline=29;md5=1bea10e81fc6f2df105b1f8b733cb149 \ > file://pppd/plugins/passprompt.c;beginline=1;endline=10;md5=3bcbcdbf0e369c9a3e0b8c8275b065d8 \ > @@ -29,7 +29,9 @@ SRC_URI[sha256sum] = "733b7f5840b613da4eab0429a5081293275f06ba8b528e1b8eea6964fa > > inherit autotools systemd > > -EXTRA_OECONF += "--with-openssl=${STAGING_EXECPREFIXDIR}" > +PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)} openssl" > +PACKAGECONFIG[pam] = "--with-pam=${STAGING_EXECPREFIXDIR},--with-pam=no,libpam" > +PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_EXECPREFIXDIR},--with-openssl=no,openssl" If inherit pkgconfig, we can avoid explicitly pointing to the installed path for openssl and libpam, otherwise this is a good substitute for my original patch. > > do_install:append () { > mkdir -p ${D}${bindir}/ ${D}${sysconfdir}/init.d > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#206565): https://lists.openembedded.org/g/openembedded-core/message/206565 > Mute This Topic: https://lists.openembedded.org/mt/109305795/3617261 > Group Owner: openembedded-core+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [danismostlikely@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- >
On Thu, 2024-10-31 at 09:53 -0600, Dan McGregor via lists.openembedded.org wrote: > On Wed, 30 Oct 2024 at 16:55, Khem Raj via lists.openembedded.org > <raj.khem=gmail.com@lists.openembedded.org> wrote: > > > > Explicitly enable pam support, otherwise it goes into > > detection mode and ends up poking at build host > > > > Turn openssl into packageconfig as well > > > > cc1: warning: include location "/usr/include" is unsafe for cross- > > compilation [-Wpoison-system-directories] > > conftest.c: In function 'main': > > conftest.c:68:1: warning: argument 1 null where non-null expected > > [-Wnonnull] > > 68 | pam_authenticate(NULL, 0); > > | ^~~~~~~~~~~~~~~~ > > In file included from conftest.c:63: > > /usr/include/security/pam_appl.h:38:1: note: in a call to function > > 'pam_authenticate' declared 'nonnull' > > 38 | pam_authenticate(pam_handle_t *pamh, int flags); > > | ^~~~~~~~~~~~~~~~ > > > > Signed-off-by: Khem Raj <raj.khem@gmail.com> > > --- > > meta/recipes-connectivity/ppp/ppp_2.5.1.bb | 6 ++++-- > > 1 file changed, 4 insertions(+), 2 deletions(-) > > > > diff --git a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > > b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > > index 5b8c49ca850..2b917905b24 100644 > > --- a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > > +++ b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb > > @@ -4,7 +4,7 @@ the Point-to-Point Protocol (PPP) on Linux and > > Solaris systems." > > SECTION = "console/network" > > HOMEPAGE = "http://samba.org/ppp/" > > BUGTRACKER = "http://ppp.samba.org/cgi-bin/ppp-bugs" > > -DEPENDS = "libpcap openssl virtual/crypt" > > +DEPENDS = "libpcap virtual/crypt" > > LICENSE = "BSD-3-Clause & BSD-3-Clause-Attribution & GPL-2.0-or- > > later & LGPL-2.0-or-later & PD & RSA-MD & MIT" > > LIC_FILES_CHKSUM = > > "file://pppd/ccp.c;beginline=1;endline=29;md5=1bea10e81fc6f2df105b1 > > f8b733cb149 \ > > > > file://pppd/plugins/passprompt.c;beginline=1;endline=10;md5=3bcbcdbf0e369c9a3e0b8c8275b065d8 > > \ > > @@ -29,7 +29,9 @@ SRC_URI[sha256sum] = > > "733b7f5840b613da4eab0429a5081293275f06ba8b528e1b8eea6964fa > > > > inherit autotools systemd > > > > -EXTRA_OECONF += "--with-openssl=${STAGING_EXECPREFIXDIR}" > > +PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)} > > openssl" > > +PACKAGECONFIG[pam] = "--with-pam=${STAGING_EXECPREFIXDIR},--with- > > pam=no,libpam" > > +PACKAGECONFIG[openssl] = "--with- > > openssl=${STAGING_EXECPREFIXDIR},--with-openssl=no,openssl" > > If inherit pkgconfig, we can avoid explicitly pointing to the > installed path for openssl and libpam, otherwise this is a good > substitute for my original patch. I do prefer the pkgconfig version FWIW. Could we have that and the pam filtering in a combined patch please? :) Cheers, Richard
diff --git a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb index 5b8c49ca850..2b917905b24 100644 --- a/meta/recipes-connectivity/ppp/ppp_2.5.1.bb +++ b/meta/recipes-connectivity/ppp/ppp_2.5.1.bb @@ -4,7 +4,7 @@ the Point-to-Point Protocol (PPP) on Linux and Solaris systems." SECTION = "console/network" HOMEPAGE = "http://samba.org/ppp/" BUGTRACKER = "http://ppp.samba.org/cgi-bin/ppp-bugs" -DEPENDS = "libpcap openssl virtual/crypt" +DEPENDS = "libpcap virtual/crypt" LICENSE = "BSD-3-Clause & BSD-3-Clause-Attribution & GPL-2.0-or-later & LGPL-2.0-or-later & PD & RSA-MD & MIT" LIC_FILES_CHKSUM = "file://pppd/ccp.c;beginline=1;endline=29;md5=1bea10e81fc6f2df105b1f8b733cb149 \ file://pppd/plugins/passprompt.c;beginline=1;endline=10;md5=3bcbcdbf0e369c9a3e0b8c8275b065d8 \ @@ -29,7 +29,9 @@ SRC_URI[sha256sum] = "733b7f5840b613da4eab0429a5081293275f06ba8b528e1b8eea6964fa inherit autotools systemd -EXTRA_OECONF += "--with-openssl=${STAGING_EXECPREFIXDIR}" +PACKAGECONFIG = "${@bb.utils.filter('DISTRO_FEATURES', 'pam', d)} openssl" +PACKAGECONFIG[pam] = "--with-pam=${STAGING_EXECPREFIXDIR},--with-pam=no,libpam" +PACKAGECONFIG[openssl] = "--with-openssl=${STAGING_EXECPREFIXDIR},--with-openssl=no,openssl" do_install:append () { mkdir -p ${D}${bindir}/ ${D}${sysconfdir}/init.d
Explicitly enable pam support, otherwise it goes into detection mode and ends up poking at build host Turn openssl into packageconfig as well cc1: warning: include location "/usr/include" is unsafe for cross-compilation [-Wpoison-system-directories] conftest.c: In function 'main': conftest.c:68:1: warning: argument 1 null where non-null expected [-Wnonnull] 68 | pam_authenticate(NULL, 0); | ^~~~~~~~~~~~~~~~ In file included from conftest.c:63: /usr/include/security/pam_appl.h:38:1: note: in a call to function 'pam_authenticate' declared 'nonnull' 38 | pam_authenticate(pam_handle_t *pamh, int flags); | ^~~~~~~~~~~~~~~~ Signed-off-by: Khem Raj <raj.khem@gmail.com> --- meta/recipes-connectivity/ppp/ppp_2.5.1.bb | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-)