Skip to contentSkip to conversation

userland: Fix a build regression in builds not using wayland

PATCH In review Khem Raj 3 participants 9 messages Apr 2, 2016 – Apr 21, 2016

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH 1/2 userland: Fix a build regression in builds not using wayland

Update userland to latest

---
 ...Fix-for-framerate-with-nested-composition.patch | 21 ++++++-----
 ...014-Fix-errors-due-to-ignored-return-code.patch | 43 ----------------------
 recipes-graphics/userland/userland_git.bb          |  3 +-
 3 files changed, 12 insertions(+), 55 deletions(-)
 delete mode 100644 recipes-graphics/userland/userland/0014-Fix-errors-due-to-ignored-return-code.patch
recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch +11 -10
index 2fa9d66..ff9ccce 100644
@@ -1,17 +1,17 @@
-From e5affc4ff145eedf61e2625a8919622c92d0b8ba Mon Sep 17 00:00:00 2001
+From f8779a124fc447b63c1ba1795330bdc2d765dc7a Mon Sep 17 00:00:00 2001
 From: Khem Raj <[email protected]>
 Date: Tue, 29 Mar 2016 20:38:30 -0700
-Subject: [PATCH 13/14] Fix for framerate with nested composition
+Subject: [PATCH 13/13] Fix for framerate with nested composition
 
 frame rate appears irregular and lower than expected when using nested composition.
 
 Signed-off-by: Khem Raj <[email protected]>
 ---
- interface/khronos/egl/egl_client.c | 9 ++++++++-
- 1 file changed, 8 insertions(+), 1 deletion(-)
+ interface/khronos/egl/egl_client.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
 
 diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 024f3ed..d8a007c 100644
+index 024f3ed..83970ec 100644
 --- a/interface/khronos/egl/egl_client.c
 +++ b/interface/khronos/egl/egl_client.c
 @@ -2342,6 +2342,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
@@ -33,7 +33,7 @@ index 024f3ed..d8a007c 100644
                    surface->front_wl_buffer->in_use = 1;
                    wl_surface_attach(wl_egl_window->wl_surface,
                                      surface->front_wl_buffer->wl_buffer,
-@@ -2360,10 +2365,11 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+@@ -2360,11 +2365,13 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
                    wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
                                      surface->width, surface->height);
                    wl_surface_commit(wl_egl_window->wl_surface);
@@ -41,12 +41,13 @@ index 024f3ed..d8a007c 100644
  
                    while(ret != -1 && surface->back_wl_buffer->in_use)
                       ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
--               } else
-+               } else {
+                } else
  #endif
++               {
                 RPC_CALL6(eglIntSwapBuffers_impl,
                       thread,
-@@ -2376,6 +2382,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                      EGLINTSWAPBUFFERS_ID,
+@@ -2376,6 +2383,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
                       RPC_UINT(khrn_platform_get_window_position(surface->win)));
  
                 RPC_FLUSH(thread);
@@ -55,5 +56,5 @@ index 024f3ed..d8a007c 100644
  #ifdef ANDROID
                 CLIENT_UNLOCK();
 -- 
-2.7.4
+2.8.0
 
recipes-graphics/userland/userland/0014-Fix-errors-due-to-ignored-return-code.patch deleted +0 -43

43 lines not on this page · raw message

recipes-graphics/userland/userland_git.bb +1 -2
index ca9123e..efa2128 100644
@@ -16,7 +16,7 @@ COMPATIBLE_MACHINE = "raspberrypi"
 
 SRCBRANCH = "master"
 SRCFORK = "raspberrypi"
-SRCREV = "2f56a2943a9eb8420df52ccf91f5a1c5a70e8713"
+SRCREV = "703a2c4b35e23ee44ad84db6b9c3f89c0a627143"
 
 SRC_URI = "\
     git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \
@@ -33,7 +33,6 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
-    file://0014-Fix-errors-due-to-ignored-return-code.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
Signature · 1 line
2.8.0
author
#1 lore raw

PATCH 2/2 userland: Make vchostif as shared library

This helps in using this library when building
with PIE binaries

---
 .../0014-build-shared-library-for-vchostif.patch   | 28 ++++++++++++++++++++++
 recipes-graphics/userland/userland_git.bb          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644 recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +28 -0
new file mode 100644
index 0000000..ca7cb66
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+ 
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+ 
+ #add_library(bufman            vc_vchi_bufman.c            )
+ 
+-- 
+2.8.0
+
recipes-graphics/userland/userland_git.bb +1 -0
index efa2128..6ed8fcf 100644
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
Signature · 1 line
2.8.0
#2 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Hi Khem,

Quoted 59 lines · Khem Raj

This helps in using this library when building
with PIE binaries

---
 .../0014-build-shared-library-for-vchostif.patch   | 28 ++++++++++++++++++++++
 recipes-graphics/userland/userland_git.bb          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644 recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +28 -0
new file mode 100644
index 0000000..ca7cb66
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+
+ #add_library(bufman            vc_vchi_bufman.c            )
+
+--
+2.8.0
+
recipes-graphics/userland/userland_git.bb +1 -1
index efa2128..6ed8fcf 100644
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

This breaks omxplayer compilation when linking omxplayer.bin:
[...]/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol
'vc_dispmanx_resource_write_data'
[...]/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding
symbols: DSO missing from command line

Regards,
Jonathan

author
#3 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Quoted 62 lines · Jonathan Liu

Hi Khem,

Quoted 59 lines · Khem Raj

This helps in using this library when building
with PIE binaries

---
 .../0014-build-shared-library-for-vchostif.patch   | 28 ++++++++++++++++++++++
 recipes-graphics/userland/userland_git.bb          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644 recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +28 -0
new file mode 100644
index 0000000..ca7cb66
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+
+ #add_library(bufman            vc_vchi_bufman.c            )
+
+--
+2.8.0
+
recipes-graphics/userland/userland_git.bb +1 -1
index efa2128..6ed8fcf 100644
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 12 lines
Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

This breaks omxplayer compilation when linking omxplayer.bin:
[...]/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol
'vc_dispmanx_resource_write_data'
[...]/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding
symbols: DSO missing from command line

Interestingly i dont see this error. Are you using gold ? see if this library is on linker cmdline or not

Quoted 3 lines

Regards,
Jonathan

#4 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Quoted 80 lines · Khem Raj
Quoted 3 lines · On Wed, Apr 13, 2016 at 3:05 AM, Jonathan Liu <[email protected]…

Hi Khem,

On 3 April 2016 at 03:59, Khem Raj <[email protected] <javascript:;>>

Quoted 6 lines · wrote:
Quoted 6 lines

This helps in using this library when building
with PIE binaries

Signed-off-by Khem Raj <[email protected] <javascript:;>>
---
 .../0014-build-shared-library-for-vchostif.patch   | 28

++++++++++++++++++++++

Quoted 3 lines
Quoted 3 lines
 recipes-graphics/userland/userland_git.bb          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644

recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

Quoted 2 lines
Quoted 2 lines

diff --git

a/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch b/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

Quoted 4 lines
Quoted 4 lines

new file mode 100644
index 0000000..ca7cb66
--- /dev/null
+++

b/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

Quoted 6 lines
Quoted 6 lines
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +5 -0
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected] <javascript:;>>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
Quoted 8 lines

recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

Quoted 8 lines
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +8 -0
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected] <javascript:;>>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt

b/interface/vmcs_host/CMakeLists.txt

Quoted 8 lines
Quoted 8 lines
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +8 -0
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+
+-add_library(vchostif ${VCHOSTIF_SOURCE})
Quoted 8 lines

Review

Quoted 8 lines
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +7 -0
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+
+ #add_library(bufman            vc_vchi_bufman.c            )
+
+--
+2.8.0
+
(quoted diff) +0 -0

b/recipes-graphics/userland/userland_git.bb

Quoted 14 lines
Quoted 14 lines

index efa2128..6ed8fcf 100644

recipes-graphics/userland/userland_git.bb +1 -1
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 8 lines
Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected] <javascript:;>
https://lists.yoctoproject.org/listinfo/yocto

This breaks omxplayer compilation when linking omxplayer.bin:

Quoted 8 lines

[...]/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:

Quoted 4 lines

omxplayer.o: undefined reference to symbol 'vc_dispmanx_resource_write_data' [...]/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding
symbols: DSO missing from command line

Interestingly i dont see this error. Are you using gold ? see if this library is on linker cmdline or not

Using whatever is the default for OE-core in master branch.

| arm-custom-linux-gnueabi-g++ -march=armv7ve -marm
-mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7
--sysroot=/home/build/git/pi2/build/tmp/sysroots/ra
spberrypi2 -L/home/build/git/pi2/build/tmp/work/cor
texa7hf-neon-vfpv4-custom-linux-gnueabi/omxplayer/gi
t-r4/git/ffmpeg_compiled/usr/lib -
L/home/build/git/pi2/build/tmp/sysroots/raspberrypi
2/lib -L/home/build/git/pi2/build
/tmp/sysroots/raspberrypi2/usr/lib
-L./ -Lffmpeg_compiled/usr/lib/ -lc -lWFC -lGLESv2
-lEGL -lbcm_host -lopenmaxil -lfreetype -lz -o omxpl
ayer.bin linux/XMemUtils.o utils/log.o DynamicDll.o
utils/PCMRemap.o utils/RegExp.o OMXSubtitleTagSami.o
OMXOverlayCodecText.o BitstreamConverter.o linux/RB
P.o OMXThread.o OMXReader.o OMXStreamInfo.o OMXAudio
CodecOMX.o OMXCore.o OMXVideo.o OMXAudio.o OMXClock.
o File.o OMXPlayerVideo.o OMXPlayerAudio.o OMXPlayer
Subtitles.o SubtitleRenderer.o Unicode.o Srt.o KeyCo
nfig.o OMXControl.o Keyboard.o omxplayer.o -lvchiq_a
rm -lvcos -ldbus-1 -lrt -lpthread -lavutil -lavcodec
-lavformat -lswscale -lswresample -lpcre
| /home/build/git/pi2/build/tmp/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol 'vc_dispmanx_resource_write_data'
|
/home/build/git/pi2/build/tmp/sysroots/raspberrypi2/usr/lib/libvchostif.so:
error adding symbols: DSO
missing from command line

| collect2: error: ld returned 1 exit status
| Makefile:53: recipe for target 'omxplayer.bin' failed
| make: *** [omxplayer.bin] Error 1
Quoted 5 lines
Quoted 4 lines

Regards,
Jonathan

author
#5 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Thats interesting, I will try to reproduce it

Quoted 114 lines · Jonathan Liu

On Thursday, 14 April 2016, Khem Raj <[email protected] <mailto:[email protected]>> wrote:

Quoted 62 lines · On Wed, Apr 13, 2016 at 3:05 AM, Jonathan Liu <[email protected]…

Hi Khem,

Quoted 59 lines · On 3 April 2016 at 03:59, Khem Raj <[email protected] <javascript:;>> wrote:

This helps in using this library when building
with PIE binaries

Signed-off-by Khem Raj <[email protected] <javascript:;>>
---
 .../0014-build-shared-library-for-vchostif.patch   | 28 ++++++++++++++++++++++
 recipes-graphics/userland/userland_git.bb <http://userland_git.bb/>          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644 recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch
recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +28 -0
new file mode 100644
index 0000000..ca7cb66
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected] <javascript:;>>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected] <javascript:;>>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt b/interface/vmcs_host/CMakeLists.txt
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+
+ #add_library(bufman            vc_vchi_bufman.c            )
+
+--
+2.8.0
+
recipes-graphics/userland/userland_git.bb <http://userland_git.bb/> +1 -1
index efa2128..6ed8fcf 100644
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 12 lines
Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected] <javascript:;>
https://lists.yoctoproject.org/listinfo/yocto <https://lists.yoctoproject.org/listinfo/yocto>

This breaks omxplayer compilation when linking omxplayer.bin:
[...]/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol
'vc_dispmanx_resource_write_data'
[...]/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding
symbols: DSO missing from command line

Interestingly i dont see this error. Are you using gold ? see if this library is on linker cmdline or not Using whatever is the default for OE-core in master branch.

| arm-custom-linux-gnueabi-g++ -march=armv7ve -marm
-mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7
--sysroot=/home/build/git/pi2/build/tmp/sysroots/ra
spberrypi2 -L/home/build/git/pi2/build/tmp/work/cor
texa7hf-neon-vfpv4-custom-linux-gnueabi/omxplayer/gi
t-r4/git/ffmpeg_compiled/usr/lib -
L/home/build/git/pi2/build/tmp/sysroots/raspberrypi
2/lib -L/home/build/git/pi2/build
/tmp/sysroots/raspberrypi2/usr/lib
-L./ -Lffmpeg_compiled/usr/lib/ -lc -lWFC -lGLESv2
-lEGL -lbcm_host -lopenmaxil -lfreetype -lz -o omxpl
ayer.bin linux/XMemUtils.o utils/log.o DynamicDll.o
utils/PCMRemap.o utils/RegExp.o OMXSubtitleTagSami.o
OMXOverlayCodecText.o BitstreamConverter.o linux/RB
P.o OMXThread.o OMXReader.o OMXStreamInfo.o OMXAudio
CodecOMX.o OMXCore.o OMXVideo.o OMXAudio.o OMXClock.
o File.o OMXPlayerVideo.o OMXPlayerAudio.o OMXPlayer
Subtitles.o SubtitleRenderer.o Unicode.o Srt.o KeyCo
nfig.o OMXControl.o Keyboard.o omxplayer.o -lvchiq_a
rm -lvcos -ldbus-1 -lrt -lpthread -lavutil -lavcodec
-lavformat -lswscale -lswresample -lpcre
| /home/build/git/pi2/build/tmp/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld: omxplayer.o: undefined reference to symbol 'vc_dispmanx_resource_write_data' | /home/build/git/pi2/build/tmp/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding symbols: DSO
missing from command line

| collect2: error: ld returned 1 exit status
| Makefile:53: recipe for target 'omxplayer.bin' failed
| make: *** [omxplayer.bin] Error 1
Quoted 3 lines

Regards,
Jonathan

#6 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Hi Khem,

Quoted 1 line · Khem Raj

Thats interesting, I will try to reproduce it

I have submitted a patch to the mailing list to bump the omxplayer revision which fixes the issue.

Quoted 122 lines · Jonathan Liu
Quoted 79 lines · Khem Raj
Quoted 77 lines · Jonathan Liu

Hi Khem,

Quoted 66 lines · Khem Raj

This helps in using this library when building
with PIE binaries

---
 .../0014-build-shared-library-for-vchostif.patch   | 28
++++++++++++++++++++++
 recipes-graphics/userland/userland_git.bb          |  1 +
 2 files changed, 29 insertions(+)
 create mode 100644

recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

diff --git a/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch b/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file mode 100644
index 0000000..ca7cb66
--- /dev/null
+++
b/recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch

recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +13 -0
@@ -0,0 +1,28 @@
+From 4e9aa3fffb458ca4fafd2241c18e9c8008b66ad8 Mon Sep 17 00:00:00 2001
+From: Khem Raj <[email protected]>
+Date: Sat, 2 Apr 2016 10:37:24 -0700
+Subject: [PATCH] build shared library for vchostif
+
+Fixes #149
+
+Signed-off-by: Khem Raj <[email protected]>
+---
+ interface/vmcs_host/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/interface/vmcs_host/CMakeLists.txt

b/interface/vmcs_host/CMakeLists.txt

recipes-graphics/userland/userland/0014-build-shared-library-for-vchostif.patch new file +15 -0
+index 22949a8..f8c2f2f 100755
+--- a/interface/vmcs_host/CMakeLists.txt
++++ b/interface/vmcs_host/CMakeLists.txt
+@@ -17,7 +17,7 @@ set(VCHOSTIF_SOURCE
+ #            ${VMCS_TARGET}/vmcs_main.c
+ #  vc_vchi_haud.c
+
+-add_library(vchostif ${VCHOSTIF_SOURCE})
++add_library(vchostif SHARED ${VCHOSTIF_SOURCE})
+
+ #add_library(bufman            vc_vchi_bufman.c            )
+
+--
+2.8.0
+
recipes-graphics/userland/userland_git.bb +1 -1
index efa2128..6ed8fcf 100644
@@ -33,6 +33,7 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
+    file://0014-build-shared-library-for-vchostif.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

This breaks omxplayer compilation when linking omxplayer.bin:

Quoted 8 lines
Quoted 5 lines

[...]/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol
'vc_dispmanx_resource_write_data'
[...]/sysroots/raspberrypi2/usr/lib/libvchostif.so: error adding
symbols: DSO missing from command line

Interestingly i dont see this error. Are you using gold ? see if this library is on linker cmdline or not

Using whatever is the default for OE-core in master branch.

| arm-custom-linux-gnueabi-g++ -march=armv7ve -marm
-mfpu=neon-vfpv4 -mfloat-abi=hard -mcpu=cortex-a7
--sysroot=/home/build/git/pi2/build/tmp/sysroots/ra
spberrypi2 -L/home/build/git/pi2/build/tmp/work/cor
texa7hf-neon-vfpv4-custom-linux-gnueabi/omxplayer/gi
t-r4/git/ffmpeg_compiled/usr/lib -
L/home/build/git/pi2/build/tmp/sysroots/raspberrypi
2/lib -L/home/build/git/pi2/build
/tmp/sysroots/raspberrypi2/usr/lib
-L./ -Lffmpeg_compiled/usr/lib/ -lc -lWFC -lGLESv2
-lEGL -lbcm_host -lopenmaxil -lfreetype -lz -o omxpl
ayer.bin linux/XMemUtils.o utils/log.o DynamicDll.o
utils/PCMRemap.o utils/RegExp.o OMXSubtitleTagSami.o
OMXOverlayCodecText.o BitstreamConverter.o linux/RB
P.o OMXThread.o OMXReader.o OMXStreamInfo.o OMXAudio
CodecOMX.o OMXCore.o OMXVideo.o OMXAudio.o OMXClock.
o File.o OMXPlayerVideo.o OMXPlayerAudio.o OMXPlayer
Subtitles.o SubtitleRenderer.o Unicode.o Srt.o KeyCo
nfig.o OMXControl.o Keyboard.o omxplayer.o -lvchiq_a
rm -lvcos -ldbus-1 -lrt -lpthread -lavutil -lavcodec
-lavformat -lswscale -lswresample -lpcre
| /home/build/git/pi2/build/tmp/sysroots/x86_64-linux/usr/libexec/arm-custom-linux-gnueabi/gcc/arm-custom-linux-gnueabi/5.3.0/ld:
omxplayer.o: undefined reference to symbol 'vc_dispmanx_resource_write_data'
|
/home/build/git/pi2/build/tmp/sysroots/raspberrypi2/usr/lib/libvchostif.so:
error adding symbols: DSO
missing from command line

Quoted 3 lines
| collect2: error: ld returned 1 exit status
| Makefile:53: recipe for target 'omxplayer.bin' failed
| make: *** [omxplayer.bin] Error 1

Regards,
Jonathan

#7 lore raw

Re: [meta-raspberrypi][PATCH 2/2] userland: Make vchostif as shared library

Quoted 8 lines · Jonathan Liu

Hi Khem,

Quoted 1 line · Khem Raj

Thats interesting, I will try to reproduce it

I have submitted a patch to the mailing list to bump the omxplayer revision which fixes the issue.

Cool. I'll take a look on it, test it and merge today. --
Andrei Gherzan

#8 lore raw
In reply to Khem Raj
Quoted 143 lines · Khem Raj

Update userland to latest

---
 ...Fix-for-framerate-with-nested-composition.patch | 21 ++++++-----
 ...014-Fix-errors-due-to-ignored-return-code.patch | 43 ----------------------
 recipes-graphics/userland/userland_git.bb          |  3 +-
 3 files changed, 12 insertions(+), 55 deletions(-)
 delete mode 100644 recipes-graphics/userland/userland/0014-Fix-errors-due-to-ignored-return-code.patch
recipes-graphics/userland/userland/0013-Fix-for-framerate-with-nested-composition.patch +11 -10
index 2fa9d66..ff9ccce 100644
@@ -1,17 +1,17 @@
-From e5affc4ff145eedf61e2625a8919622c92d0b8ba Mon Sep 17 00:00:00 2001
+From f8779a124fc447b63c1ba1795330bdc2d765dc7a Mon Sep 17 00:00:00 2001
 From: Khem Raj <[email protected]>
 Date: Tue, 29 Mar 2016 20:38:30 -0700
-Subject: [PATCH 13/14] Fix for framerate with nested composition
+Subject: [PATCH 13/13] Fix for framerate with nested composition
 
 frame rate appears irregular and lower than expected when using nested composition.
 
 Signed-off-by: Khem Raj <[email protected]>
 ---
- interface/khronos/egl/egl_client.c | 9 ++++++++-
- 1 file changed, 8 insertions(+), 1 deletion(-)
+ interface/khronos/egl/egl_client.c | 8 ++++++++
+ 1 file changed, 8 insertions(+)
 
 diff --git a/interface/khronos/egl/egl_client.c b/interface/khronos/egl/egl_client.c
-index 024f3ed..d8a007c 100644
+index 024f3ed..83970ec 100644
 --- a/interface/khronos/egl/egl_client.c
 +++ b/interface/khronos/egl/egl_client.c
 @@ -2342,6 +2342,9 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
@@ -33,7 +33,7 @@ index 024f3ed..d8a007c 100644
                    surface->front_wl_buffer->in_use = 1;
                    wl_surface_attach(wl_egl_window->wl_surface,
                                      surface->front_wl_buffer->wl_buffer,
-@@ -2360,10 +2365,11 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+@@ -2360,11 +2365,13 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
                    wl_surface_damage(wl_egl_window->wl_surface, 0, 0,
                                      surface->width, surface->height);
                    wl_surface_commit(wl_egl_window->wl_surface);
@@ -41,12 +41,13 @@ index 024f3ed..d8a007c 100644
 
                    while(ret != -1 && surface->back_wl_buffer->in_use)
                       ret = wl_display_dispatch_queue(wl_display, process->wl_queue);
--               } else
-+               } else {
+                } else
  #endif
++               {
                 RPC_CALL6(eglIntSwapBuffers_impl,
                       thread,
-@@ -2376,6 +2382,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
+                      EGLINTSWAPBUFFERS_ID,
+@@ -2376,6 +2383,7 @@ EGLAPI EGLBoolean EGLAPIENTRY eglSwapBuffers(EGLDisplay dpy, EGLSurface surf)
                       RPC_UINT(khrn_platform_get_window_position(surface->win)));
 
                 RPC_FLUSH(thread);
@@ -55,5 +56,5 @@ index 024f3ed..d8a007c 100644
  #ifdef ANDROID
                 CLIENT_UNLOCK();
 --
-2.7.4
+2.8.0
 
recipes-graphics/userland/userland/0014-Fix-errors-due-to-ignored-return-code.patch deleted +0 -43
deleted file mode 100644
index 2d11e9b..0000000
@@ -1,43 +0,0 @@
-From 8ac57765d8b971aaa5ee5c610d8df25fa2ea36da Mon Sep 17 00:00:00 2001
-From: Khem Raj <[email protected]>
-Date: Thu, 24 Mar 2016 15:03:50 -0700
-Subject: [PATCH 14/14] Fix errors due to ignored return code
-
-Clang warns/errors about not checking the return
-values from chdir() and fread(), here we check
-for chdir return code and report back using error()
-API, and second fix to fread is to let compiler
-ignore the value via assigning it to an unused variable
-
-Signed-off-by: Khem Raj <[email protected]>
----
- host_applications/linux/apps/dtoverlay/dtoverlay_main.c | 6 ++++--
- 1 file changed, 4 insertions(+), 2 deletions(-)
-
-diff --git a/host_applications/linux/apps/dtoverlay/dtoverlay_main.c b/host_applications/linux/apps/dtoverlay/dtoverlay_main.c
-index 4b33809..fa8324f 100755
---- a/host_applications/linux/apps/dtoverlay/dtoverlay_main.c
-+++ b/host_applications/linux/apps/dtoverlay/dtoverlay_main.c
-@@ -353,7 +353,8 @@ static int dtoverlay_remove(STATE_T *state, const char *overlay)
-     int rmpos;
-     int i;
-
--    chdir(work_dir);
-+    if (chdir(work_dir) != 0)
-+	return error("chdir to %s failed", work_dir);
-
-     overlay_dir = sprintf_dup("%s/%s", dt_overlays_dir, overlay);
-     if (!dir_exists(overlay_dir))
-@@ -633,7 +634,8 @@ static int overlay_applied(const char *overlay_dir)
-     FILE *fp = fopen(status_path, "r");
-     if (fp)
-     {
--	fread(status, sizeof(status), 1, fp);
-+	int bytes __attribute__((unused));
-+	bytes = fread(status, sizeof(status), 1, fp);
- 	fclose(fp);
-     }
-     free_string(status_path);
---
-2.7.4
-
recipes-graphics/userland/userland_git.bb +1 -3
index ca9123e..efa2128 100644
@@ -16,7 +16,7 @@ COMPATIBLE_MACHINE = "raspberrypi"
 
 SRCBRANCH = "master"
 SRCFORK = "raspberrypi"
-SRCREV = "2f56a2943a9eb8420df52ccf91f5a1c5a70e8713"
+SRCREV = "703a2c4b35e23ee44ad84db6b9c3f89c0a627143"
 
 SRC_URI = "\
     git://github.com/${SRCFORK}/userland.git;protocol=git;branch=${SRCBRANCH} \
@@ -33,7 +33,6 @@ SRC_URI = "\
     file://0011-fix-cmake-dependency-race.patch \
     file://0012-Fix-enum-conversion-warnings.patch \
     file://0013-Fix-for-framerate-with-nested-composition.patch \
-    file://0014-Fix-errors-due-to-ignored-return-code.patch \
     file://0015-wl-dispmanx-buffer-wrapping.patch \
 "
 S = "${WORKDIR}/git"
--

2.8.0

Quoted 5 lines

--
_______________________________________________
yocto mailing list
[email protected]
https://lists.yoctoproject.org/listinfo/yocto

Merged both patches. Thanks.

--
Andrei Gherzan