[1/5] fltk/CMake: Do not export executable 'fluid'

Submitted by Andreas Müller on Aug. 19, 2021, 11:02 a.m. | Patch ID: 180111

Details

Message ID 20210819110248.3505349-1-schnitzeltony@gmail.com
State Accepted
Commit f45df170dc8ece71b4025636605b7b425d7673ea
Headers show

Commit Message

Andreas Müller Aug. 19, 2021, 11:02 a.m.
It does not work for us: The executable 'fluid' is not installed in
receipe-sysroot. So fltk cmake config contains an invalid reference.
Consumers of fltk using cmake will fail during configure for this invalid
reference with something like:

| CMake Error at <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
|   The imported target "fluid" references the file
|
|      "<...>/recipe-sysroot/usr/bin/fluid"
|
|   but this file does not exist.

Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
---
 meta-oe/recipes-support/fltk/fltk.bb          |  2 +
 ...Lists.txt-Do-not-export-fluid-target.patch | 42 +++++++++++++++++++
 2 files changed, 44 insertions(+)
 create mode 100644 meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch

Patch hide | download patch | download mbox

diff --git a/meta-oe/recipes-support/fltk/fltk.bb b/meta-oe/recipes-support/fltk/fltk.bb
index ca2b517d7..3c9ee5ee3 100644
--- a/meta-oe/recipes-support/fltk/fltk.bb
+++ b/meta-oe/recipes-support/fltk/fltk.bb
@@ -5,6 +5,8 @@  DEPENDS = "alsa-lib zlib jpeg libpng libxext libxft"
 inherit features_check binconfig lib_package gtk-icon-cache mime mime-xdg
 REQUIRED_DISTRO_FEATURES = "x11"
 
+SRC_URI += "file://0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch"
+
 EXTRA_OECMAKE = " \
     -DOPTION_BUILD_SHARED_LIBS=ON \
     -DOPTION_USE_THREADS=ON \
diff --git a/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch b/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
new file mode 100644
index 000000000..72bb48a32
--- /dev/null
+++ b/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
@@ -0,0 +1,42 @@ 
+From b6985abcb03fb09685da4044963e8f085035b208 Mon Sep 17 00:00:00 2001
+From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
+Date: Thu, 19 Aug 2021 08:06:45 +0200
+Subject: [PATCH] fluid/CMakeLists.txt: Do not export fluid target
+MIME-Version: 1.0
+Content-Type: text/plain; charset=UTF-8
+Content-Transfer-Encoding: 8bit
+
+It does not work for us: The executable 'fluid' is not installed in
+receipe-sysroot. So fltk cmake config contains an invalid reference.
+Consumers of fltk using cmake will fail during configure for this invalid
+reference with something like:
+
+| CMake Error at <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
+|   The imported target "fluid" references the file
+| 
+|      "<...>/recipe-sysroot/usr/bin/fluid"
+| 
+|   but this file does not exist.
+
+Upstream-Status: Inappropriate [OE specific]
+
+Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
+---
+ fluid/CMakeLists.txt | 1 -
+ 1 file changed, 1 deletion(-)
+
+diff --git a/fluid/CMakeLists.txt b/fluid/CMakeLists.txt
+index 472c84c..f971121 100644
+--- a/fluid/CMakeLists.txt
++++ b/fluid/CMakeLists.txt
+@@ -86,7 +86,6 @@ if (APPLE AND (NOT OPTION_APPLE_X11))
+   install (TARGETS fluid DESTINATION ${FLTK_BINDIR})
+ else()
+   install (TARGETS fluid
+-    EXPORT FLTK-Targets
+     RUNTIME DESTINATION ${FLTK_BINDIR}
+     LIBRARY DESTINATION ${FLTK_LIBDIR}
+     ARCHIVE DESTINATION ${FLTK_LIBDIR}
+-- 
+2.31.1
+

Comments

Khem Raj Aug. 19, 2021, 2:12 p.m.
On Thu, Aug 19, 2021 at 4:02 AM Andreas Müller <schnitzeltony@gmail.com>
wrote:

> It does not work for us: The executable 'fluid' is not installed in
> receipe-sysroot. So fltk cmake config contains an invalid reference.
> Consumers of fltk using cmake will fail during configure for this invalid
> reference with something like:
>
> | CMake Error at
> <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
> |   The imported target "fluid" references the file
> |
> |      "<...>/recipe-sysroot/usr/bin/fluid"
> |
> |   but this file does not exist.


Do we get it from native sysroot then ? Or is it not required at all for
cross compiles

>
>
> Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
> ---
>  meta-oe/recipes-support/fltk/fltk.bb          |  2 +
>  ...Lists.txt-Do-not-export-fluid-target.patch | 42 +++++++++++++++++++
>  2 files changed, 44 insertions(+)
>  create mode 100644
> meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
>
> diff --git a/meta-oe/recipes-support/fltk/fltk.bb
> b/meta-oe/recipes-support/fltk/fltk.bb
> index ca2b517d7..3c9ee5ee3 100644
> --- a/meta-oe/recipes-support/fltk/fltk.bb
> +++ b/meta-oe/recipes-support/fltk/fltk.bb
> @@ -5,6 +5,8 @@ DEPENDS = "alsa-lib zlib jpeg libpng libxext libxft"
>  inherit features_check binconfig lib_package gtk-icon-cache mime mime-xdg
>  REQUIRED_DISTRO_FEATURES = "x11"
>
> +SRC_URI +=
> "file://0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch"
> +
>  EXTRA_OECMAKE = " \
>      -DOPTION_BUILD_SHARED_LIBS=ON \
>      -DOPTION_USE_THREADS=ON \
> diff --git
> a/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
> b/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
> new file mode 100644
> index 000000000..72bb48a32
> --- /dev/null
> +++
> b/meta-oe/recipes-support/fltk/fltk/0003-fluid-CMakeLists.txt-Do-not-export-fluid-target.patch
> @@ -0,0 +1,42 @@
> +From b6985abcb03fb09685da4044963e8f085035b208 Mon Sep 17 00:00:00 2001
> +From: =?UTF-8?q?Andreas=20M=C3=BCller?= <schnitzeltony@gmail.com>
> +Date: Thu, 19 Aug 2021 08:06:45 +0200
> +Subject: [PATCH] fluid/CMakeLists.txt: Do not export fluid target
> +MIME-Version: 1.0
> +Content-Type: text/plain; charset=UTF-8
> +Content-Transfer-Encoding: 8bit
> +
> +It does not work for us: The executable 'fluid' is not installed in
> +receipe-sysroot. So fltk cmake config contains an invalid reference.
> +Consumers of fltk using cmake will fail during configure for this invalid
> +reference with something like:
> +
> +| CMake Error at
> <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
> +|   The imported target "fluid" references the file
> +|
> +|      "<...>/recipe-sysroot/usr/bin/fluid"
> +|
> +|   but this file does not exist.
> +
> +Upstream-Status: Inappropriate [OE specific]
> +
> +Signed-off-by: Andreas Müller <schnitzeltony@gmail.com>
> +---
> + fluid/CMakeLists.txt | 1 -
> + 1 file changed, 1 deletion(-)
> +
> +diff --git a/fluid/CMakeLists.txt b/fluid/CMakeLists.txt
> +index 472c84c..f971121 100644
> +--- a/fluid/CMakeLists.txt
> ++++ b/fluid/CMakeLists.txt
> +@@ -86,7 +86,6 @@ if (APPLE AND (NOT OPTION_APPLE_X11))
> +   install (TARGETS fluid DESTINATION ${FLTK_BINDIR})
> + else()
> +   install (TARGETS fluid
> +-    EXPORT FLTK-Targets
> +     RUNTIME DESTINATION ${FLTK_BINDIR}
> +     LIBRARY DESTINATION ${FLTK_LIBDIR}
> +     ARCHIVE DESTINATION ${FLTK_LIBDIR}
> +--
> +2.31.1
> +
> --
> 2.31.1
>
>
> 
>
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#92667): https://lists.openembedded.org/g/openembedded-devel/message/92667
Mute This Topic: https://lists.openembedded.org/mt/84993977/3617530
Group Owner: openembedded-devel+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Andreas Müller Aug. 19, 2021, 5:28 p.m.
On Thu, Aug 19, 2021 at 4:12 PM Khem Raj <raj.khem@gmail.com> wrote:
>
>
>
> On Thu, Aug 19, 2021 at 4:02 AM Andreas Müller <schnitzeltony@gmail.com> wrote:
>>
>> It does not work for us: The executable 'fluid' is not installed in
>> receipe-sysroot. So fltk cmake config contains an invalid reference.
>> Consumers of fltk using cmake will fail during configure for this invalid
>> reference with something like:
>>
>> | CMake Error at <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
>> |   The imported target "fluid" references the file
>> |
>> |      "<...>/recipe-sysroot/usr/bin/fluid"
>> |
>> |   but this file does not exist.
>
>
> Do we get it from native sysroot then ? Or is it not required at all for cross compiles
Hi Khem,

Native fluid is supplied by flk-native (and I have recipes in
meta-musicians using it). This patch just fixes invalid cmake config
and leaves flk-native untouched. In my opinion this export does not
make sense anyway because fluid does not export re-usable libraries
and just calling 'fluid' will work because it is installed in standard
bindir folder.

Hope that helps.

Andreas
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#92669): https://lists.openembedded.org/g/openembedded-devel/message/92669
Mute This Topic: https://lists.openembedded.org/mt/84993977/3617530
Group Owner: openembedded-devel+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-
Khem Raj Aug. 19, 2021, 5:36 p.m.
On 8/19/21 10:28 AM, Andreas Müller wrote:
> On Thu, Aug 19, 2021 at 4:12 PM Khem Raj <raj.khem@gmail.com> wrote:
>>
>>
>>
>> On Thu, Aug 19, 2021 at 4:02 AM Andreas Müller <schnitzeltony@gmail.com> wrote:
>>>
>>> It does not work for us: The executable 'fluid' is not installed in
>>> receipe-sysroot. So fltk cmake config contains an invalid reference.
>>> Consumers of fltk using cmake will fail during configure for this invalid
>>> reference with something like:
>>>
>>> | CMake Error at <...>/recipe-sysroot/usr/share/fltk/FLTK-Targets.cmake:129 (message):
>>> |   The imported target "fluid" references the file
>>> |
>>> |      "<...>/recipe-sysroot/usr/bin/fluid"
>>> |
>>> |   but this file does not exist.
>>
>>
>> Do we get it from native sysroot then ? Or is it not required at all for cross compiles
> Hi Khem,
> 
> Native fluid is supplied by flk-native (and I have recipes in
> meta-musicians using it). This patch just fixes invalid cmake config
> and leaves flk-native untouched. In my opinion this export does not
> make sense anyway because fluid does not export re-usable libraries
> and just calling 'fluid' will work because it is installed in standard
> bindir folder.
> 
> Hope that helps.

yes it does thanks.

> 
> Andreas
>
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.
View/Reply Online (#92671): https://lists.openembedded.org/g/openembedded-devel/message/92671
Mute This Topic: https://lists.openembedded.org/mt/84993977/3617530
Group Owner: openembedded-devel+owner@lists.openembedded.org
Unsubscribe: https://lists.openembedded.org/g/openembedded-devel/unsub [oe-patchwork@oe-patch.openembedded.org]
-=-=-=-=-=-=-=-=-=-=-=-