Hi everybody! I successfully built an image for an ARM based system running a PostgreSQL server and client by adding the packages "postgresql" and "postgresql-client". However, so far I failed to make the development stuff (libpq-fe.h, pg_config, etc) available in the generated SDK.
Usuallly one uses pg_config to obtain the required include path (pg_config --includedir), the required compiler flags for C and C++ (pg_config --cflags and pg_config --cppflags) as well as the required linker flags (pg_config --libdir and pg_config --ldflags). However, I get the warning during compilation of my own programs: cc1plus: warning: include location "/usr/include/postgresql" is unsafe for cross-compilation [-Wpoison-system-directories] Obviously the native pg_config binary of my Ubuntu system is called and hence causes references to the local installation of the libpq-dev package of my Ubuntu system instead of a pg_config binary provided by the SDK. Even worse, the SDK just includes the pg_config binary for the ARM platform, but not for x86_64. The only way to silence these warnings is to include -Wno-poison-system-directories in my compiler flags. But this is something I really like to avoid. Who knows whether the PostgreSQL development stuff of my local Ubuntu system will always be compatible to the one for the ARM system? Unfortunately I had no luck including the PostgreSQL development stuff in the SDK. I already tried 'TOOLCHAIN_HOST_TASK_append = " nativesdk-postgresql"', but this ends in an error message like this: ERROR: Nothing RPROVIDES 'nativesdk-postgresql' (but /opt/PHYTEC_BSPs/yocto_imx7/sources/poky/meta/recipes-core/meta/buildtools-tarball.bb, /opt/PHYTEC_BSPs/yocto_imx7/sources/poky/meta/recipes-core/meta/uninative-tarball.bb RDEPENDS on or otherwise requires it) NOTE: Runtime target 'nativesdk-postgresql' is unbuildable, removing... Missing or unbuildable dependency chain was: ['nativesdk-postgresql'] ERROR: Required build target 'fsl-image-qt5' has no buildable providers. Missing or unbuildable dependency chain was: ['fsl-image-qt5', 'buildtools-tarball', 'nativesdk-postgresql'] Adding 'PACKAGECONFIG_append_pn-nativesdk += " postgresql"' also does not cause the x86_64 binary of pg_config to be included in the SDK. I assume this causes the ARM binary to be included, but this cannot be used on an x86_64 system. I searched lots of sites for a solution already, but so far I only found hints how to add packages in general, but nothing in respect to this specific issue. Can anybody please point out what I am doing wrong or what I need to change to solve this issue? Many thanks in advance! Mit freundlichem Gruß best regards iNOEX GmbH Thore Böckelmann Software Design Mit freundlichen Grüßen / Kind regards i. A. Thore Böckelmann iNOEX GmbH | Maschweg 70 | 49324 Melle | Germany | www.inoex.de<http://www.inoex.de/> Dipl.-Inform. Thore Böckelmann Software Engineering [email protected]<mailto:[email protected]> FON +49 5422 60507-958<callto:+49%205422%2060507-958> | FAX +49 5422 60507-101<callto:+49%205422%2060507-101> Follow us on [cid:signatur_linkedin_612a1331-e3ca-46d8-92e7-c497d1f53ff6.png] <https://www.linkedin.com/company/3911295> <https://plus.google.com/113636118318392148063> <https://plus.google.com/113636118318392148063> [cid:signatur_inoex_890ef8cb-96e8-4640-bcd9-a6be63c22320.jpg] ________________________________ iNOEX GmbH Innovationen und Ausruestungen fuer die Extrusionstechnik Geschaeftsfuehrer / Managing Director: Martin Deters, Jan Lohoff Sitz der Gesellschaft / Headquarter: Maschweg 70, D-49324 Melle Registergericht / Register: Amtsgericht Osnabrück Handelsregisternummer / Registration number: HRB 207338 Bitte beachten Sie die Datenschutzinformationen <https://www.inoex.de/index.php?id=642#6510>
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#54930): https://lists.yoctoproject.org/g/yocto/message/54930 Mute This Topic: https://lists.yoctoproject.org/mt/86024693/21656 Group Owner: [email protected] Unsubscribe: https://lists.yoctoproject.org/g/yocto/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
