Message ID | 20231027194914.78513-1-peron.clem@gmail.com |
---|---|
State | Under Review |
Headers | show |
Series | [v2] connectivity: add pcapplusplus recipe | expand |
> -----Original Message----- > From: openembedded-devel@lists.openembedded.org <openembedded-devel@lists.openembedded.org> On Behalf Of Clément Péron > Sent: den 27 oktober 2023 21:49 > To: openembedded-devel@lists.openembedded.org > Cc: Clément Péron <peron.clem@gmail.com> > Subject: [oe] [PATCH v2] connectivity: add pcapplusplus recipe A more standard subject would be something like: pcapplusplus: Add recipe > > Add PcapPlusPlus 23.09 recipe. > > Signed-off-by: Clément Péron <peron.clem@gmail.com> > --- > .../pcapplusplus/pcapplusplus_23.09.bb | 21 +++++++++++++++++++ > 1 file changed, 21 insertions(+) > create mode 100644 meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > diff --git a/meta-oe/recipes- > connectivity/pcapplusplus/pcapplusplus_23.09.bb b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > new file mode 100644 > index 000000000..39c6942c8 > --- /dev/null > +++ b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > @@ -0,0 +1,21 @@ > +SUMMARY = "A multiplatform C++ library for capturing, parsing and crafting of network packets" > +HOMEPAGE = "https://pcapplusplus.github.io/" > +BUGTRACKER = "https://github.com/seladb/PcapPlusPlus/issues" > +SECTION = "libs/network" > +LICENSE = "Unlicense" > +LIC_FILES_CHKSUM = "file://LICENSE;md5=911690f51af322440237a253d695d19f" > + > +DEPENDS = "libpcap" > + > +SRC_URI = "git://github.com/seladb/PcapPlusPlus.git;protocol=https;branch=master" > +SRCREV = "4cf8ed44f9dd145f874dc1dd747dfefcfcab75be" > + > +S = "${WORKDIR}/git" > + > +inherit cmake > + > +PACKAGECONFIG ??= "" > +PACKAGECONFIG[examples] = "-DPCAPPP_BUILD_EXAMPLES=ON,-DPCAPPP_BUILD_EXAMPLES=OFF" > +PACKAGECONFIG[shared] = "-DBUILD_SHARED_LIBS=ON,-DBUILD_SHARED_LIBS=OFF" Did you really mean to not enable the "shared" PACAKEGCONFIG, and thus only build static libraries? That seems very odd. > +PACKAGECONFIG[tests] = "-DPCAPPP_BUILD_TESTS=ON,-DPCAPPP_BUILD_TESTS=OFF" > +PACKAGECONFIG[zstd] = "-DLIGHT_PCAPNG_ZSTD=ON,-DLIGHT_PCAPNG_ZSTD=OFF,zstd" Since it is unlikely that anyone wants to enable the examples and only build statically, I would suggest replacing the first two PACKAGECONFIGs above with: EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF" And unless you plan on adding ptest support, you may as well remove the tests PACKAGECONFIG too, and make that: EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF -DPCAPPP_BUILD_TESTS=OFF" And if either of those three matches the upstream defaults, you can of course remove it altogether. > -- > 2.39.3 (Apple Git-145) //Peter
Hi Peter, On Fri, 27 Oct 2023 at 22:40, Peter Kjellerstedt <peter.kjellerstedt@axis.com> wrote: > > > -----Original Message----- > > From: openembedded-devel@lists.openembedded.org <openembedded-devel@lists.openembedded.org> On Behalf Of Clément Péron > > Sent: den 27 oktober 2023 21:49 > > To: openembedded-devel@lists.openembedded.org > > Cc: Clément Péron <peron.clem@gmail.com> > > Subject: [oe] [PATCH v2] connectivity: add pcapplusplus recipe > > A more standard subject would be something like: > > pcapplusplus: Add recipe > > > > > Add PcapPlusPlus 23.09 recipe. > > > > Signed-off-by: Clément Péron <peron.clem@gmail.com> > > --- > > .../pcapplusplus/pcapplusplus_23.09.bb | 21 +++++++++++++++++++ > > 1 file changed, 21 insertions(+) > > create mode 100644 meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > > > diff --git a/meta-oe/recipes- > > connectivity/pcapplusplus/pcapplusplus_23.09.bb b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > new file mode 100644 > > index 000000000..39c6942c8 > > --- /dev/null > > +++ b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > @@ -0,0 +1,21 @@ > > +SUMMARY = "A multiplatform C++ library for capturing, parsing and crafting of network packets" > > +HOMEPAGE = "https://pcapplusplus.github.io/" > > +BUGTRACKER = "https://github.com/seladb/PcapPlusPlus/issues" > > +SECTION = "libs/network" > > +LICENSE = "Unlicense" > > +LIC_FILES_CHKSUM = "file://LICENSE;md5=911690f51af322440237a253d695d19f" > > + > > +DEPENDS = "libpcap" > > + > > +SRC_URI = "git://github.com/seladb/PcapPlusPlus.git;protocol=https;branch=master" > > +SRCREV = "4cf8ed44f9dd145f874dc1dd747dfefcfcab75be" > > + > > +S = "${WORKDIR}/git" > > + > > +inherit cmake > > + > > +PACKAGECONFIG ??= "" > > +PACKAGECONFIG[examples] = "-DPCAPPP_BUILD_EXAMPLES=ON,-DPCAPPP_BUILD_EXAMPLES=OFF" > > +PACKAGECONFIG[shared] = "-DBUILD_SHARED_LIBS=ON,-DBUILD_SHARED_LIBS=OFF" > > Did you really mean to not enable the "shared" PACAKEGCONFIG, > and thus only build static libraries? That seems very odd. Thanks for your feedback, indeed in my application I only use a small part of Pcap++ and don't want to have all the Pcap++ shared library. Also the shared library is not the default behavior on PcapPP repo as they are some issues with Windows DLL. > > > +PACKAGECONFIG[tests] = "-DPCAPPP_BUILD_TESTS=ON,-DPCAPPP_BUILD_TESTS=OFF" > > +PACKAGECONFIG[zstd] = "-DLIGHT_PCAPNG_ZSTD=ON,-DLIGHT_PCAPNG_ZSTD=OFF,zstd" > > Since it is unlikely that anyone wants to enable the examples and > only build statically, I would suggest replacing the first two > PACKAGECONFIGs above with: Examples may be bad naming. It's more like "Tools" which binaries like Arping, DnsSpoofing, HttpAnalyzer, etc... Then inside these Examples there are trivial ones that are called "Tutorials" which the configuration is not configurable here. > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF" > > And unless you plan on adding ptest support, you may as well remove the > tests PACKAGECONFIG too, and make that: > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF -DPCAPPP_BUILD_TESTS=OFF" > > And if either of those three matches the upstream defaults, > you can of course remove it altogether. So you prefer to have everything defined with EXTRA_OECMAKE. Why not let the user have this configurable through packageconfig if it's possible and doesn't cost? Thanks Clement > > > -- > > 2.39.3 (Apple Git-145) > > //Peter
Hi Peter, +Khem On Sat, 28 Oct 2023 at 12:20, Clément Péron via lists.openembedded.org <peron.clem=gmail.com@lists.openembedded.org> wrote: > > Hi Peter, > > On Fri, 27 Oct 2023 at 22:40, Peter Kjellerstedt > <peter.kjellerstedt@axis.com> wrote: > > > > > -----Original Message----- > > > From: openembedded-devel@lists.openembedded.org <openembedded-devel@lists.openembedded.org> On Behalf Of Clément Péron > > > Sent: den 27 oktober 2023 21:49 > > > To: openembedded-devel@lists.openembedded.org > > > Cc: Clément Péron <peron.clem@gmail.com> > > > Subject: [oe] [PATCH v2] connectivity: add pcapplusplus recipe > > > > A more standard subject would be something like: > > > > pcapplusplus: Add recipe Is it ok, if I send a v3 changing the subject and enabling the shared option by default. But leaving the other packageconfig available. Does that seem good to you? > > > > > > > > Add PcapPlusPlus 23.09 recipe. > > > > > > Signed-off-by: Clément Péron <peron.clem@gmail.com> > > > --- > > > .../pcapplusplus/pcapplusplus_23.09.bb | 21 +++++++++++++++++++ > > > 1 file changed, 21 insertions(+) > > > create mode 100644 meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > > > > > diff --git a/meta-oe/recipes- > > > connectivity/pcapplusplus/pcapplusplus_23.09.bb b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > > new file mode 100644 > > > index 000000000..39c6942c8 > > > --- /dev/null > > > +++ b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > > @@ -0,0 +1,21 @@ > > > +SUMMARY = "A multiplatform C++ library for capturing, parsing and crafting of network packets" > > > +HOMEPAGE = "https://pcapplusplus.github.io/" > > > +BUGTRACKER = "https://github.com/seladb/PcapPlusPlus/issues" > > > +SECTION = "libs/network" > > > +LICENSE = "Unlicense" > > > +LIC_FILES_CHKSUM = "file://LICENSE;md5=911690f51af322440237a253d695d19f" > > > + > > > +DEPENDS = "libpcap" > > > + > > > +SRC_URI = "git://github.com/seladb/PcapPlusPlus.git;protocol=https;branch=master" > > > +SRCREV = "4cf8ed44f9dd145f874dc1dd747dfefcfcab75be" > > > + > > > +S = "${WORKDIR}/git" > > > + > > > +inherit cmake > > > + > > > +PACKAGECONFIG ??= "" > > > +PACKAGECONFIG[examples] = "-DPCAPPP_BUILD_EXAMPLES=ON,-DPCAPPP_BUILD_EXAMPLES=OFF" > > > +PACKAGECONFIG[shared] = "-DBUILD_SHARED_LIBS=ON,-DBUILD_SHARED_LIBS=OFF" > > > > Did you really mean to not enable the "shared" PACAKEGCONFIG, > > and thus only build static libraries? That seems very odd. > > Thanks for your feedback, indeed in my application I only use a small > part of Pcap++ and don't want to have all the Pcap++ shared library. > > Also the shared library is not the default behavior on PcapPP repo as > they are some issues with Windows DLL. > > > > > > +PACKAGECONFIG[tests] = "-DPCAPPP_BUILD_TESTS=ON,-DPCAPPP_BUILD_TESTS=OFF" > > > +PACKAGECONFIG[zstd] = "-DLIGHT_PCAPNG_ZSTD=ON,-DLIGHT_PCAPNG_ZSTD=OFF,zstd" > > > > Since it is unlikely that anyone wants to enable the examples and > > only build statically, I would suggest replacing the first two > > PACKAGECONFIGs above with: > > Examples may be bad naming. It's more like "Tools" which binaries like > Arping, DnsSpoofing, HttpAnalyzer, etc... > > Then inside these Examples there are trivial ones that are called "Tutorials" > which the configuration is not configurable here. > > > > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF" > > > > And unless you plan on adding ptest support, you may as well remove the > > tests PACKAGECONFIG too, and make that: > > > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF -DPCAPPP_BUILD_TESTS=OFF" > > > > And if either of those three matches the upstream defaults, > > you can of course remove it altogether. > > So you prefer to have everything defined with EXTRA_OECMAKE. > > Why not let the user have this configurable through packageconfig if > it's possible and doesn't cost? > > Thanks > Clement > > > > > > -- > > > 2.39.3 (Apple Git-145) > > > > //Peter > > -=-=-=-=-=-=-=-=-=-=-=- > Links: You receive all messages sent to this group. > View/Reply Online (#105785): https://lists.openembedded.org/g/openembedded-devel/message/105785 > Mute This Topic: https://lists.openembedded.org/mt/102228837/4240582 > Group Owner: openembedded-devel+owner@lists.openembedded.org > Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [peron.clem@gmail.com] > -=-=-=-=-=-=-=-=-=-=-=- >
Please send the delta as a new patch the v2 is merged On Mon, Oct 30, 2023 at 6:27 AM Clément Péron <peron.clem@gmail.com> wrote: > Hi Peter, > > +Khem > > On Sat, 28 Oct 2023 at 12:20, Clément Péron via lists.openembedded.org > <peron.clem=gmail.com@lists.openembedded.org> wrote: > > > > Hi Peter, > > > > On Fri, 27 Oct 2023 at 22:40, Peter Kjellerstedt > > <peter.kjellerstedt@axis.com> wrote: > > > > > > > -----Original Message----- > > > > From: openembedded-devel@lists.openembedded.org < > openembedded-devel@lists.openembedded.org> On Behalf Of Clément Péron > > > > Sent: den 27 oktober 2023 21:49 > > > > To: openembedded-devel@lists.openembedded.org > > > > Cc: Clément Péron <peron.clem@gmail.com> > > > > Subject: [oe] [PATCH v2] connectivity: add pcapplusplus recipe > > > > > > A more standard subject would be something like: > > > > > > pcapplusplus: Add recipe > > Is it ok, if I send a v3 changing the subject and enabling the shared > option by default. > > But leaving the other packageconfig available. > > Does that seem good to you? > > > > > > > > > > > > > Add PcapPlusPlus 23.09 recipe. > > > > > > > > Signed-off-by: Clément Péron <peron.clem@gmail.com> > > > > --- > > > > .../pcapplusplus/pcapplusplus_23.09.bb | 21 > +++++++++++++++++++ > > > > 1 file changed, 21 insertions(+) > > > > create mode 100644 meta-oe/recipes-connectivity/pcapplusplus/ > pcapplusplus_23.09.bb > > > > > > > > diff --git a/meta-oe/recipes- > > > > connectivity/pcapplusplus/pcapplusplus_23.09.bb > b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb > > > > new file mode 100644 > > > > index 000000000..39c6942c8 > > > > --- /dev/null > > > > +++ b/meta-oe/recipes-connectivity/pcapplusplus/ > pcapplusplus_23.09.bb > > > > @@ -0,0 +1,21 @@ > > > > +SUMMARY = "A multiplatform C++ library for capturing, parsing and > crafting of network packets" > > > > +HOMEPAGE = "https://pcapplusplus.github.io/" > > > > +BUGTRACKER = "https://github.com/seladb/PcapPlusPlus/issues" > > > > +SECTION = "libs/network" > > > > +LICENSE = "Unlicense" > > > > +LIC_FILES_CHKSUM = > "file://LICENSE;md5=911690f51af322440237a253d695d19f" > > > > + > > > > +DEPENDS = "libpcap" > > > > + > > > > +SRC_URI = "git:// > github.com/seladb/PcapPlusPlus.git;protocol=https;branch=master" > > > > +SRCREV = "4cf8ed44f9dd145f874dc1dd747dfefcfcab75be" > > > > + > > > > +S = "${WORKDIR}/git" > > > > + > > > > +inherit cmake > > > > + > > > > +PACKAGECONFIG ??= "" > > > > +PACKAGECONFIG[examples] = > "-DPCAPPP_BUILD_EXAMPLES=ON,-DPCAPPP_BUILD_EXAMPLES=OFF" > > > > +PACKAGECONFIG[shared] = > "-DBUILD_SHARED_LIBS=ON,-DBUILD_SHARED_LIBS=OFF" > > > > > > Did you really mean to not enable the "shared" PACAKEGCONFIG, > > > and thus only build static libraries? That seems very odd. > > > > Thanks for your feedback, indeed in my application I only use a small > > part of Pcap++ and don't want to have all the Pcap++ shared library. > > > > Also the shared library is not the default behavior on PcapPP repo as > > they are some issues with Windows DLL. > > > > > > > > > +PACKAGECONFIG[tests] = > "-DPCAPPP_BUILD_TESTS=ON,-DPCAPPP_BUILD_TESTS=OFF" > > > > +PACKAGECONFIG[zstd] = > "-DLIGHT_PCAPNG_ZSTD=ON,-DLIGHT_PCAPNG_ZSTD=OFF,zstd" > > > > > > Since it is unlikely that anyone wants to enable the examples and > > > only build statically, I would suggest replacing the first two > > > PACKAGECONFIGs above with: > > > > Examples may be bad naming. It's more like "Tools" which binaries like > > Arping, DnsSpoofing, HttpAnalyzer, etc... > > > > Then inside these Examples there are trivial ones that are called > "Tutorials" > > which the configuration is not configurable here. > > > > > > > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF" > > > > > > And unless you plan on adding ptest support, you may as well remove the > > > tests PACKAGECONFIG too, and make that: > > > > > > EXTRA_OECMAKE += "-DBUILD_SHARED_LIBS=ON -DPCAPPP_BUILD_EXAMPLES=OFF > -DPCAPPP_BUILD_TESTS=OFF" > > > > > > And if either of those three matches the upstream defaults, > > > you can of course remove it altogether. > > > > So you prefer to have everything defined with EXTRA_OECMAKE. > > > > Why not let the user have this configurable through packageconfig if > > it's possible and doesn't cost? > > > > Thanks > > Clement > > > > > > > > > -- > > > > 2.39.3 (Apple Git-145) > > > > > > //Peter > > > > -=-=-=-=-=-=-=-=-=-=-=- > > Links: You receive all messages sent to this group. > > View/Reply Online (#105785): > https://lists.openembedded.org/g/openembedded-devel/message/105785 > > Mute This Topic: https://lists.openembedded.org/mt/102228837/4240582 > > Group Owner: openembedded-devel+owner@lists.openembedded.org > > Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [ > peron.clem@gmail.com] > > -=-=-=-=-=-=-=-=-=-=-=- > > >
diff --git a/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb new file mode 100644 index 000000000..39c6942c8 --- /dev/null +++ b/meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb @@ -0,0 +1,21 @@ +SUMMARY = "A multiplatform C++ library for capturing, parsing and crafting of network packets" +HOMEPAGE = "https://pcapplusplus.github.io/" +BUGTRACKER = "https://github.com/seladb/PcapPlusPlus/issues" +SECTION = "libs/network" +LICENSE = "Unlicense" +LIC_FILES_CHKSUM = "file://LICENSE;md5=911690f51af322440237a253d695d19f" + +DEPENDS = "libpcap" + +SRC_URI = "git://github.com/seladb/PcapPlusPlus.git;protocol=https;branch=master" +SRCREV = "4cf8ed44f9dd145f874dc1dd747dfefcfcab75be" + +S = "${WORKDIR}/git" + +inherit cmake + +PACKAGECONFIG ??= "" +PACKAGECONFIG[examples] = "-DPCAPPP_BUILD_EXAMPLES=ON,-DPCAPPP_BUILD_EXAMPLES=OFF" +PACKAGECONFIG[shared] = "-DBUILD_SHARED_LIBS=ON,-DBUILD_SHARED_LIBS=OFF" +PACKAGECONFIG[tests] = "-DPCAPPP_BUILD_TESTS=ON,-DPCAPPP_BUILD_TESTS=OFF" +PACKAGECONFIG[zstd] = "-DLIGHT_PCAPNG_ZSTD=ON,-DLIGHT_PCAPNG_ZSTD=OFF,zstd"
Add PcapPlusPlus 23.09 recipe. Signed-off-by: Clément Péron <peron.clem@gmail.com> --- .../pcapplusplus/pcapplusplus_23.09.bb | 21 +++++++++++++++++++ 1 file changed, 21 insertions(+) create mode 100644 meta-oe/recipes-connectivity/pcapplusplus/pcapplusplus_23.09.bb