From 51f3d2678ac7052a3c0848903126023a7cb79b74 Mon Sep 17 00:00:00 2001 From: Atsushi Watanabe Date: Mon, 29 Jul 2024 16:39:50 +0900 Subject: [PATCH] Fix -dev split rule (#173) --- .github/workflows/build.yaml | 9 +++++++++ generate_rospkg_apkbuild/APKBUILD.em.sh | 17 ++++++++++------- 2 files changed, 19 insertions(+), 7 deletions(-) diff --git a/.github/workflows/build.yaml b/.github/workflows/build.yaml index 13184b1..0dd98c4 100644 --- a/.github/workflows/build.yaml +++ b/.github/workflows/build.yaml @@ -71,6 +71,15 @@ jobs: run: | echo "Checking dev package" ls -l /tmp/apks/*/* | grep -e "${{ steps.test-data.outputs.apk-pkg-name }}-dev-[[:alnum:]\._git]\+-r0.apk" + - name: Show package contents + run: | + for apk in /tmp/apks/*/*/*.apk; do + echo "-----" + echo ${apk} + echo "-----" + tar -tvf ${apk} 2>/dev/null + echo + done - name: Login to GitHub Container Registry if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/master' }} diff --git a/generate_rospkg_apkbuild/APKBUILD.em.sh b/generate_rospkg_apkbuild/APKBUILD.em.sh index efd015d..de5a269 100644 --- a/generate_rospkg_apkbuild/APKBUILD.em.sh +++ b/generate_rospkg_apkbuild/APKBUILD.em.sh @@ -396,14 +396,17 @@ dev() { mkdir -p $subpkgdir install_if="${subpkgname%-dev}=$pkgver-r$pkgrel ros-dev" - if ls $pkgdir/usr/ros/*/lib/pkgconfig >/dev/null 2>/dev/null; then - amove 'usr/ros/*/lib/pkgconfig' - fi - if ls $pkgdir/usr/ros/*/share/*/cmake >/dev/null 2>/dev/null; then - amove 'usr/ros/*/share/*/cmake' - fi + cd $pkgdir || return 0 - default_dev + for i in \ + usr/ros/*/lib/pkgconfig \ + usr/ros/*/share/*/cmake \ + usr/ros/*/include \ + $(find usr/ros/*/lib -name -name '*.[choa]' -o -name '*.prl' 2>/dev/null); do + if [ -e "$i" ] || [ -L "$i" ]; then + amove "$i" + fi + done } @[end if] if [ -f ./apkbuild_hook.sh ]; then