diff options
author | Kai Kang <kai.kang@windriver.com> | 2022-03-10 07:28:51 +0800 |
---|---|---|
committer | Khem Raj <raj.khem@gmail.com> | 2022-03-10 07:31:21 -0800 |
commit | 10e9b26163e0efcdea1cd90f2cfba4672dcbee83 (patch) | |
tree | f43d2318bf9c9295b6e7af578253d273e124e7e2 | |
parent | 669b1eb6ba68ecde1726f2d686c49237618c1117 (diff) | |
download | meta-openembedded-10e9b26163e0efcdea1cd90f2cfba4672dcbee83.tar.gz |
wxwidgets: fix install errors
There are errors during do install. So link files 'wx-config' and 'wxrc'
are not created, and rename failed either:
| CMake Error: failed to create symbolic link '/usr/bin/wx-config': Permission denied
| Error renaming from "/usr/bin/wxrc" to "/usr/bin/wxrc-3.1": No such file or directory
| CMake Error: failed to create symbolic link '/usr/bin/wxrc': Permission denied
Respect variable 'DESTDIR' to make it work as expect.
And package ${libdir}/wx/config/gtk3-unicode-3.1 to ${PN}-dev that
/usr/bin/wx-config from ${PN}-dev links to it.
Signed-off-by: Kai Kang <kai.kang@windriver.com>
Signed-off-by: Khem Raj <raj.khem@gmail.com>
-rw-r--r-- | meta-oe/recipes-extended/wxwidgets/wxwidgets/respect-DESTDIR-when-create-link.patch | 55 | ||||
-rw-r--r-- | meta-oe/recipes-extended/wxwidgets/wxwidgets_git.bb | 6 |
2 files changed, 60 insertions, 1 deletions
diff --git a/meta-oe/recipes-extended/wxwidgets/wxwidgets/respect-DESTDIR-when-create-link.patch b/meta-oe/recipes-extended/wxwidgets/wxwidgets/respect-DESTDIR-when-create-link.patch new file mode 100644 index 0000000000..69be32928c --- /dev/null +++ b/meta-oe/recipes-extended/wxwidgets/wxwidgets/respect-DESTDIR-when-create-link.patch | |||
@@ -0,0 +1,55 @@ | |||
1 | There are errors during do install. So link files 'wx-config' and 'wxrc' are | ||
2 | not created, and rename failed either: | ||
3 | |||
4 | | CMake Error: failed to create symbolic link '/usr/bin/wx-config': Permission denied | ||
5 | | Error renaming from "/usr/bin/wxrc" to "/usr/bin/wxrc-3.1": No such file or directory | ||
6 | | CMake Error: failed to create symbolic link '/usr/bin/wxrc': Permission denied | ||
7 | |||
8 | Respect variable 'DESTDIR' to make it work as expect. | ||
9 | |||
10 | Upstream-Status: Pending | ||
11 | |||
12 | Signed-off-by: Kai Kang <kai.kang@windriver.com> | ||
13 | --- | ||
14 | build/cmake/install.cmake | 4 ++-- | ||
15 | build/cmake/utils/CMakeLists.txt | 8 ++++---- | ||
16 | 2 files changed, 6 insertions(+), 6 deletions(-) | ||
17 | |||
18 | diff --git a/build/cmake/install.cmake b/build/cmake/install.cmake | ||
19 | index c850c51844..5cbc67daa1 100644 | ||
20 | --- a/build/cmake/install.cmake | ||
21 | +++ b/build/cmake/install.cmake | ||
22 | @@ -46,8 +46,8 @@ else() | ||
23 | install(DIRECTORY DESTINATION "bin") | ||
24 | install(CODE "execute_process( \ | ||
25 | COMMAND ${CMAKE_COMMAND} -E create_symlink \ | ||
26 | - ${CMAKE_INSTALL_PREFIX}/lib${wxPLATFORM_LIB_DIR}/wx/config/${wxBUILD_FILE_ID} \ | ||
27 | - ${CMAKE_INSTALL_PREFIX}/bin/wx-config \ | ||
28 | + ../lib${wxPLATFORM_LIB_DIR}/wx/config/${wxBUILD_FILE_ID} \ | ||
29 | + \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/wx-config \ | ||
30 | )" | ||
31 | ) | ||
32 | endif() | ||
33 | diff --git a/build/cmake/utils/CMakeLists.txt b/build/cmake/utils/CMakeLists.txt | ||
34 | index 4108d6a723..fbac6bb533 100644 | ||
35 | --- a/build/cmake/utils/CMakeLists.txt | ||
36 | +++ b/build/cmake/utils/CMakeLists.txt | ||
37 | @@ -34,14 +34,14 @@ if(wxUSE_XRC) | ||
38 | if(NOT MSVC) | ||
39 | install(CODE "execute_process( \ | ||
40 | COMMAND ${CMAKE_COMMAND} -E rename \ | ||
41 | - ${CMAKE_INSTALL_PREFIX}/bin/wxrc${EXE_SUFFIX} \ | ||
42 | - ${CMAKE_INSTALL_PREFIX}/bin/wxrc-${wxMAJOR_VERSION}.${wxMINOR_VERSION}${EXE_SUFFIX} \ | ||
43 | + \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/wxrc${EXE_SUFFIX} \ | ||
44 | + \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/wxrc-${wxMAJOR_VERSION}.${wxMINOR_VERSION}${EXE_SUFFIX} \ | ||
45 | )" | ||
46 | ) | ||
47 | install(CODE "execute_process( \ | ||
48 | COMMAND ${CMAKE_COMMAND} -E create_symlink \ | ||
49 | - ${CMAKE_INSTALL_PREFIX}/bin/wxrc-${wxMAJOR_VERSION}.${wxMINOR_VERSION}${EXE_SUFFIX} \ | ||
50 | - ${CMAKE_INSTALL_PREFIX}/bin/wxrc${EXE_SUFFIX} \ | ||
51 | + wxrc-${wxMAJOR_VERSION}.${wxMINOR_VERSION}${EXE_SUFFIX} \ | ||
52 | + \$ENV{DESTDIR}${CMAKE_INSTALL_PREFIX}/bin/wxrc${EXE_SUFFIX} \ | ||
53 | )" | ||
54 | ) | ||
55 | endif() | ||
diff --git a/meta-oe/recipes-extended/wxwidgets/wxwidgets_git.bb b/meta-oe/recipes-extended/wxwidgets/wxwidgets_git.bb index 724bc00840..b4420a18ea 100644 --- a/meta-oe/recipes-extended/wxwidgets/wxwidgets_git.bb +++ b/meta-oe/recipes-extended/wxwidgets/wxwidgets_git.bb | |||
@@ -25,6 +25,7 @@ SRC_URI = " \ | |||
25 | git://github.com/wxWidgets/wxWidgets.git;branch=master;protocol=https \ | 25 | git://github.com/wxWidgets/wxWidgets.git;branch=master;protocol=https \ |
26 | file://0001-wx-config.in-Disable-cross-magic-it-does-not-work-fo.patch \ | 26 | file://0001-wx-config.in-Disable-cross-magic-it-does-not-work-fo.patch \ |
27 | file://fix-libdir-for-multilib.patch \ | 27 | file://fix-libdir-for-multilib.patch \ |
28 | file://respect-DESTDIR-when-create-link.patch \ | ||
28 | " | 29 | " |
29 | PV = "3.1.4" | 30 | PV = "3.1.4" |
30 | SRCREV= "6cdaedd42ba59331b3dc4ead50e0bac76ae14c19" | 31 | SRCREV= "6cdaedd42ba59331b3dc4ead50e0bac76ae14c19" |
@@ -103,4 +104,7 @@ FILES:${PN} += " \ | |||
103 | ${libdir}/wx/ \ | 104 | ${libdir}/wx/ \ |
104 | " | 105 | " |
105 | 106 | ||
106 | FILES:${PN}-dev += "${libdir}/wx/include/" | 107 | FILES:${PN}-dev += " \ |
108 | ${libdir}/wx/include/ \ | ||
109 | ${libdir}/wx/config/ \ | ||
110 | " | ||