diff --git a/.github/workflows/crankshaft.yml b/.github/workflows/crankshaft.yml index 568797cf..a073230e 100644 --- a/.github/workflows/crankshaft.yml +++ b/.github/workflows/crankshaft.yml @@ -23,6 +23,14 @@ jobs: sha1_filename: ${{ steps.get-artifact-name.outputs.sha1_filename }} sha256_path: ${{ steps.get-artifact-name.outputs.sha256_path }} sha256_filename: ${{ steps.get-artifact-name.outputs.sha256_filename }} + pi2_artifact_path: ${{ steps.get-artifact-name.outputs.artifact_path }} + pi2_artifact_filename: ${{ steps.get-artifact-name-pi2.outputs.artifact_filename }} + pi2_md5_path: ${{ steps.get-artifact-name-pi2.outputs.md5_path }} + pi2_md5_filename: ${{ steps.get-artifact-name-pi2.outputs.md5_filename }} + pi2_sha1_path: ${{ steps.get-artifact-name-pi2.outputs.sha1_path }} + pi2_sha1_filename: ${{ steps.get-artifact-name-pi2.outputs.sha1_filename }} + pi2_sha256_path: ${{ steps.get-artifact-name-pi2.outputs.sha256_path }} + pi2_sha256_filename: ${{ steps.get-artifact-name-pi2.outputs.sha256_filename }} version: ${{ steps.get_version.outputs.version }} builddate: ${{ steps.get_version.outputs.builddate }} steps: @@ -88,21 +96,42 @@ jobs: name: Get Name of Artifact id: get-artifact-name run: | - ls -hla - ARTIFACT_PATHNAME=$(ls ./deploy/*.zip | head -n 1) + ls -hla deploy/* + ARTIFACT_PATHNAME=$(ls deploy/*[!-pi2].zip | head -n 1) ARTIFACT_NAME=$(basename $ARTIFACT_PATHNAME) + MD5_PATHNAME=$(ls deploy/*[!-pi2].img.md5 | head -n 1) + MD5_NAME=$(basename $MD5_PATHNAME) + SHA1_PATHNAME=$(ls deploy/*[!-pi2].sha1 | head -n 1) + SHA1_NAME=$(basename $SHA1_PATHNAME) + SHA256_PATHNAME=$(ls deploy/*[!-pi2].sha256 | head -n 1) + SHA256_NAME=$(basename $SHA256_PATHNAME) echo ::set-output name=artifact_filename::${ARTIFACT_NAME} echo ::set-output name=artifact_path::${ARTIFACT_PATHNAME} - MD5_PATHNAME=$(ls ./deploy/*.md5 | head -n 1) - MD5_NAME=$(basename $MD5_PATHNAME) echo ::set-output name=md5_filename::${MD5_NAME} echo ::set-output name=md5_path::${MD5_PATHNAME} - SHA1_PATHNAME=$(ls ./deploy/*.sha1 | head -n 1) - SHA1_NAME=$(basename $SHA1_PATHNAME) echo ::set-output name=sha1_filename::${SHA1_NAME} echo ::set-output name=sha1_path::${SHA1_PATHNAME} - SHA256_PATHNAME=$(ls ./deploy/*.sha256 | head -n 1) + echo ::set-output name=sha256_filename::${SHA256_NAME} + echo ::set-output name=sha256_path::${SHA256_PATHNAME} + - + name: Get Name of Artifact - pi2 + id: get-artifact-name-pi2 + run: | + ls -hla deploy/* + ARTIFACT_PATHNAME=$(ls deploy/*[-pi2].zip | head -n 1) + ARTIFACT_NAME=$(basename $ARTIFACT_PATHNAME) + MD5_PATHNAME=$(ls deploy/*[-pi2].img.md5 | head -n 1) + MD5_NAME=$(basename $MD5_PATHNAME) + SHA1_PATHNAME=$(ls deploy/*[-pi2].sha1 | head -n 1) + SHA1_NAME=$(basename $SHA1_PATHNAME) + SHA256_PATHNAME=$(ls deploy/*[-pi2].sha256 | head -n 1) SHA256_NAME=$(basename $SHA256_PATHNAME) + echo ::set-output name=artifact_filename::${ARTIFACT_NAME} + echo ::set-output name=artifact_path::${ARTIFACT_PATHNAME} + echo ::set-output name=md5_filename::${MD5_NAME} + echo ::set-output name=md5_path::${MD5_PATHNAME} + echo ::set-output name=sha1_filename::${SHA1_NAME} + echo ::set-output name=sha1_path::${SHA1_PATHNAME} echo ::set-output name=sha256_filename::${SHA256_NAME} echo ::set-output name=sha256_path::${SHA256_PATHNAME} - @@ -116,6 +145,10 @@ jobs: ${{ steps.get-artifact-name.outputs.md5_path }} ${{ steps.get-artifact-name.outputs.sha1_path }} ${{ steps.get-artifact-name.outputs.sha256_path }} + ${{ steps.get-artifact-name-pi2.outputs.artifact_path }} + ${{ steps.get-artifact-name-pi2.outputs.md5_path }} + ${{ steps.get-artifact-name-pi2.outputs.sha1_path }} + ${{ steps.get-artifact-name-pi2.outputs.sha256_path }} ./pi-gen/deploy/build.log release: name: Create release @@ -144,21 +177,42 @@ jobs: name: Get Name of Artifact id: get-artifact-name run: | - ls -hla - ARTIFACT_PATHNAME=$(ls deploy/*.zip | head -n 1) + ls -hla deploy/* + ARTIFACT_PATHNAME=$(ls deploy/*[!-pi2].zip | head -n 1) ARTIFACT_NAME=$(basename $ARTIFACT_PATHNAME) + MD5_PATHNAME=$(ls deploy/*[!-pi2].img.md5 | head -n 1) + MD5_NAME=$(basename $MD5_PATHNAME) + SHA1_PATHNAME=$(ls deploy/*[!-pi2].sha1 | head -n 1) + SHA1_NAME=$(basename $SHA1_PATHNAME) + SHA256_PATHNAME=$(ls deploy/*[!-pi2].sha256 | head -n 1) + SHA256_NAME=$(basename $SHA256_PATHNAME) echo ::set-output name=artifact_filename::${ARTIFACT_NAME} echo ::set-output name=artifact_path::${ARTIFACT_PATHNAME} - MD5_PATHNAME=$(ls deploy/*.md5 | head -n 1) - MD5_NAME=$(basename $MD5_PATHNAME) echo ::set-output name=md5_filename::${MD5_NAME} echo ::set-output name=md5_path::${MD5_PATHNAME} - SHA1_PATHNAME=$(ls deploy/*.sha1 | head -n 1) - SHA1_NAME=$(basename $SHA1_PATHNAME) echo ::set-output name=sha1_filename::${SHA1_NAME} echo ::set-output name=sha1_path::${SHA1_PATHNAME} - SHA256_PATHNAME=$(ls deploy/*.sha256 | head -n 1) + echo ::set-output name=sha256_filename::${SHA256_NAME} + echo ::set-output name=sha256_path::${SHA256_PATHNAME} + - + name: Get Name of Artifact - pi2 + id: get-artifact-name-pi2 + run: | + ls -hla deploy/* + ARTIFACT_PATHNAME=$(ls deploy/*[-pi2].zip | head -n 1) + ARTIFACT_NAME=$(basename $ARTIFACT_PATHNAME) + MD5_PATHNAME=$(ls deploy/*[-pi2].img.md5 | head -n 1) + MD5_NAME=$(basename $MD5_PATHNAME) + SHA1_PATHNAME=$(ls deploy/*[-pi2].sha1 | head -n 1) + SHA1_NAME=$(basename $SHA1_PATHNAME) + SHA256_PATHNAME=$(ls deploy/*[-pi2].sha256 | head -n 1) SHA256_NAME=$(basename $SHA256_PATHNAME) + echo ::set-output name=artifact_filename::${ARTIFACT_NAME} + echo ::set-output name=artifact_path::${ARTIFACT_PATHNAME} + echo ::set-output name=md5_filename::${MD5_NAME} + echo ::set-output name=md5_path::${MD5_PATHNAME} + echo ::set-output name=sha1_filename::${SHA1_NAME} + echo ::set-output name=sha1_path::${SHA1_PATHNAME} echo ::set-output name=sha256_filename::${SHA256_NAME} echo ::set-output name=sha256_path::${SHA256_PATHNAME} - @@ -172,9 +226,20 @@ jobs: asset_path: ${{ steps.get-artifact-name.outputs.artifact_path }} asset_name: ${{ steps.get-artifact-name.outputs.artifact_filename }} asset_content_type: application/zip + - + name: Upload Release Asset -pi2 + id: upload-release-asset-pi2 + uses: actions/upload-release-asset@v1.0.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ${{ steps.get-artifact-name-pi2.outputs.artifact_path }} + asset_name: ${{ steps.get-artifact-name-pi2.outputs.artifact_filename }} + asset_content_type: application/zip - name: Upload Release MD5 - id: upload-release-md5 + id: upload-release-md5 uses: actions/upload-release-asset@v1.0.2 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -183,6 +248,17 @@ jobs: asset_path: ${{ steps.get-artifact-name.outputs.md5_path }} asset_name: ${{ steps.get-artifact-name.outputs.md5_filename }} asset_content_type: text/plain + - + name: Upload Release MD5 -pi2 + id: upload-release-md5-pi2 + uses: actions/upload-release-asset@v1.0.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ${{ steps.get-artifact-name-pi2.outputs.md5_path }} + asset_name: ${{ steps.get-artifact-name-pi2.outputs.md5_filename }} + asset_content_type: text/plain - name: Upload Release SHA1 id: upload-release-sha1 @@ -194,9 +270,20 @@ jobs: asset_path: ${{ steps.get-artifact-name.outputs.sha1_path }} asset_name: ${{ steps.get-artifact-name.outputs.sha1_filename }} asset_content_type: text/plain + - + name: Upload Release SHA1 -pi2 + id: upload-release-sha1-pi2 + uses: actions/upload-release-asset@v1.0.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ${{ steps.get-artifact-name-pi2.outputs.sha1_path }} + asset_name: ${{ steps.get-artifact-name-pi2.outputs.sha1_filename }} + asset_content_type: text/plain - name: Upload Release SHA256 - id: upload-release-SHA256 + id: upload-release-SHA256 uses: actions/upload-release-asset@v1.0.2 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -205,3 +292,14 @@ jobs: asset_path: ${{ steps.get-artifact-name.outputs.sha256_path }} asset_name: ${{ steps.get-artifact-name.outputs.sha256_filename }} asset_content_type: text/plain + - + name: Upload Release SHA256 -pi2 + id: upload-release-SHA256-pi2 + uses: actions/upload-release-asset@v1.0.2 + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} + with: + upload_url: ${{ steps.create_release.outputs.upload_url }} # This pulls from the CREATE RELEASE step above, referencing it's ID to get its outputs object, which include a `upload_url`. See this blog post for more info: https://jasonet.co/posts/new-features-of-github-actions/#passing-data-to-future-steps + asset_path: ${{ steps.get-artifact-name-pi2.outputs.sha256_path }} + asset_name: ${{ steps.get-artifact-name-pi2.outputs.sha256_filename }} + asset_content_type: text/plain diff --git a/.github/workflows/pifile.yml b/.github/workflows/pifile.yml index ffdecd45..b3d0b69e 100644 --- a/.github/workflows/pifile.yml +++ b/.github/workflows/pifile.yml @@ -130,7 +130,7 @@ jobs: - name: Build Changelog id: github_release - uses: mikepenz/release-changelog-builder-action@v2.7.2 + uses: mikepenz/release-changelog-builder-action@v2.8.2 env: GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} - diff --git a/export-image/04-finalise/01-run.sh b/export-image/04-finalise/01-run.sh index 486d663e..b4906535 100755 --- a/export-image/04-finalise/01-run.sh +++ b/export-image/04-finalise/01-run.sh @@ -89,9 +89,9 @@ mkdir -p "${DEPLOY_DIR}" rm -f "${DEPLOY_DIR}/${ZIP_FILENAME}${IMG_SUFFIX}.zip" rm -f "${DEPLOY_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.img" pushd "${STAGE_WORK_DIR}" > /dev/null - MD5HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}.img.md5" - SHA1HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}.sha1" - SHA256HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}.sha256" + MD5HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.img.md5" + SHA1HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.sha1" + SHA256HASH="${STAGE_WORK_DIR}/${IMG_FILENAME}${IMG_SUFFIX}.sha256" md5sum "$(basename "${IMG_FILE}")" > "$(basename "${MD5HASH}")" sha1sum "$(basename "${IMG_FILE}")" > "$(basename "${SHA1HASH}")" sha256sum "$(basename "${IMG_FILE}")" > "$(basename "${SHA256HASH}")" diff --git a/prebuilts b/prebuilts index 31b64f34..83717f61 160000 --- a/prebuilts +++ b/prebuilts @@ -1 +1 @@ -Subproject commit 31b64f345fa20d7856f2cf8553ff7193a8b85b89 +Subproject commit 83717f61999400da4e4a107fc3f29e2e55e832af diff --git a/stage3/03-crankshaft-base/01-run.sh b/stage3/03-crankshaft-base/01-run.sh index cf7aa44f..7033d236 100755 --- a/stage3/03-crankshaft-base/01-run.sh +++ b/stage3/03-crankshaft-base/01-run.sh @@ -1,6 +1,7 @@ #!/bin/bash -e # /boot +install -m 644 files/boot/config.txt "${ROOTFS_DIR}/boot/" install -d "${ROOTFS_DIR}/boot/crankshaft" install -m 644 files/boot/crankshaft/gpio2kbd.cfg "${ROOTFS_DIR}/boot/crankshaft/" install -m 644 files/boot/crankshaft/openauto.ini "${ROOTFS_DIR}/boot/crankshaft/" diff --git a/stage3/03-crankshaft-base/02-run-chroot.sh b/stage3/03-crankshaft-base/02-run-chroot.sh index ddb0b471..e269c436 100755 --- a/stage3/03-crankshaft-base/02-run-chroot.sh +++ b/stage3/03-crankshaft-base/02-run-chroot.sh @@ -49,7 +49,7 @@ echo "start_cd=1" >> /boot/config.txt echo "#dtoverlay=sdtweak,overclock_50=100" >> /boot/config.txt # enable vc4 for rpi3 as well -sed -i 's/#dtoverlay=vc4-fkms-v3d/dtoverlay=vc4-fkms-v3d/' /boot/config.txt +#sed -i 's/#dtoverlay=vc4-fkms-v3d/dtoverlay=vc4-fkms-v3d/' /boot/config.txt # pulseaudio cat /etc/pulse/csng_daemon.conf >> /etc/pulse/daemon.conf diff --git a/stage3/03-crankshaft-base/07-run-chroot.sh b/stage3/03-crankshaft-base/07-run-chroot.sh new file mode 100644 index 00000000..d753c8e4 --- /dev/null +++ b/stage3/03-crankshaft-base/07-run-chroot.sh @@ -0,0 +1,6 @@ +#!/bin/bash -e +# fix Pi2 eglfs on Buster +ln -s /opt/vc/lib/libbrcmEGL.so /usr/lib/arm-linux-gnueabihf/libEGL.so +ln -s /opt/vc/lib/libbrcmGLESv2.so /usr/lib/arm-linux-gnueabihf/libGLESv2.so +ln -s /opt/vc/lib/libbrcmOpenVG.so /usr/lib/arm-linux-gnueabihf/libOpenVG.so +ln -s /opt/vc/lib/libbrcmWFC.so /usr/lib/arm-linux-gnueabihf/libWFC.so diff --git a/stage3/03-crankshaft-base/files/boot/config.txt b/stage3/03-crankshaft-base/files/boot/config.txt new file mode 100644 index 00000000..a03c2719 --- /dev/null +++ b/stage3/03-crankshaft-base/files/boot/config.txt @@ -0,0 +1,86 @@ +# For more options and information see +# http://rpf.io/configtxt +# Some settings may impact device functionality. See link above for details + +# uncomment if you get no picture on HDMI for a default "safe" mode +#hdmi_safe=1 + +# uncomment this if your display has a black border of unused pixels visible +# and your display can output without overscan +#disable_overscan=1 + +# uncomment the following to adjust overscan. Use positive numbers if console +# goes off screen, and negative if there is too much border +#overscan_left=16 +#overscan_right=16 +#overscan_top=16 +#overscan_bottom=16 + +# uncomment to force a console size. By default it will be display's size minus +# overscan. +#framebuffer_width=1280 +#framebuffer_height=720 + +# uncomment if hdmi display is not detected and composite is being output +#hdmi_force_hotplug=1 + +# uncomment to force a specific HDMI mode (this will force VGA) +#hdmi_group=1 +#hdmi_mode=1 + +# uncomment to force a HDMI mode rather than DVI. This can make audio work in +# DMT (computer monitor) modes +#hdmi_drive=2 + +# uncomment to increase signal to HDMI, if you have interference, blanking, or +# no display +#config_hdmi_boost=4 + +# uncomment for composite PAL +#sdtv_mode=2 + +#uncomment to overclock the arm. 700 MHz is the default. +#arm_freq=800 + +# Uncomment some or all of these to enable the optional hardware interfaces +#dtparam=i2c_arm=on +#dtparam=i2s=on +#dtparam=spi=on + +# Uncomment this to enable infrared communication. +#dtoverlay=gpio-ir,gpio_pin=17 +#dtoverlay=gpio-ir-tx,gpio_pin=18 + +# Additional overlays and parameters are documented /boot/overlays/README + +# Enable audio (loads snd_bcm2835) +dtparam=audio=on + +[pi0] + +[pi1] +# GPU Mem +gpu_mem=128 + +[pi2] +# GPU Mem +gpu_mem=128 + +[pi3] +# Bluetooth +dtoverlay=pi3-disable-bt +dtoverlay=vc4-fkms-v3d +# GPU Mem +gpu_mem=128 + +[pi4] +# Enable DRM VC4 V3D driver on top of the dispmanx display stack +dtoverlay=vc4-fkms-v3d +max_framebuffers=2 +# GPU Mem +gpu_mem=128 + +[all] + + + diff --git a/stage3/04-crankshaft-bluetooth/01-run-chroot.sh b/stage3/04-crankshaft-bluetooth/01-run-chroot.sh index 25fd984e..beaf5916 100755 --- a/stage3/04-crankshaft-bluetooth/01-run-chroot.sh +++ b/stage3/04-crankshaft-bluetooth/01-run-chroot.sh @@ -18,9 +18,9 @@ systemctl enable btdevicedetect systemctl enable btrestore # config.txt -echo "" >> /boot/config.txt -echo "# Bluetooth" >> /boot/config.txt -echo "dtoverlay=pi3-disable-bt" >> /boot/config.txt +#echo "" >> /boot/config.txt +#echo "# Bluetooth" >> /boot/config.txt +#echo "dtoverlay=pi3-disable-bt" >> /boot/config.txt usermod -G bluetooth -a pi usermod -G bluetooth -a pulse diff --git a/stage3/EXPORT_IMAGE b/stage3/EXPORT_IMAGE index 79ec11a3..6c8ec421 100644 --- a/stage3/EXPORT_IMAGE +++ b/stage3/EXPORT_IMAGE @@ -1,4 +1,4 @@ -IMG_SUFFIX="" +IMG_SUFFIX="-pi2" if [ "${USE_QEMU}" = "1" ]; then export IMG_SUFFIX="${IMG_SUFFIX}-qemu" fi diff --git a/stage4/01-armv7-fixes/00-run.sh b/stage4/01-armv7-fixes/00-run.sh new file mode 100644 index 00000000..f3151a7f --- /dev/null +++ b/stage4/01-armv7-fixes/00-run.sh @@ -0,0 +1,7 @@ +#!/bin/bash -e + +# qt5 from prebuilts +cat $BASE_DIR/prebuilts/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz* > files/qt5/Qt5_OpenGLES2.tar.xz + +#qt5 +tar -xf files/qt5/Qt5_OpenGLES2.tar.xz -C ${ROOTFS_DIR}/ \ No newline at end of file diff --git a/stage4/01-armv7-fixes/files/qt5/.gitignore b/stage4/01-armv7-fixes/files/qt5/.gitignore new file mode 100644 index 00000000..e69de29b diff --git a/stage4/EXPORT_IMAGE b/stage4/EXPORT_IMAGE new file mode 100644 index 00000000..79ec11a3 --- /dev/null +++ b/stage4/EXPORT_IMAGE @@ -0,0 +1,4 @@ +IMG_SUFFIX="" +if [ "${USE_QEMU}" = "1" ]; then + export IMG_SUFFIX="${IMG_SUFFIX}-qemu" +fi diff --git a/stage4/EXPORT_NOOBS b/stage4/EXPORT_NOOBS new file mode 100644 index 00000000..b7fe4eee --- /dev/null +++ b/stage4/EXPORT_NOOBS @@ -0,0 +1,2 @@ +NOOBS_NAME="Crankshaft pi2" +NOOBS_DESCRIPTION="A turnkey GNU/Linux solution that transforms a Raspberry Pi to an Android Auto head unit" diff --git a/stage4/prerun.sh b/stage4/prerun.sh new file mode 100644 index 00000000..9acd13cb --- /dev/null +++ b/stage4/prerun.sh @@ -0,0 +1,5 @@ +#!/bin/bash -e + +if [ ! -d "${ROOTFS_DIR}" ]; then + copy_previous +fi diff --git a/updater/base_buster_arm7.Pifile b/updater/base_buster_arm7.Pifile index 65fcd7e9..be28a9a9 100644 --- a/updater/base_buster_arm7.Pifile +++ b/updater/base_buster_arm7.Pifile @@ -16,6 +16,8 @@ cd /root rm -rf /usr/local/qt5 wget https://github.com/opencardev/prebuilts/raw/master/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz.part00 wget https://github.com/opencardev/prebuilts/raw/master/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz.part01 +wget https://github.com/opencardev/prebuilts/raw/master/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz.part02 +wget https://github.com/opencardev/prebuilts/raw/master/qt5/Qt_5151_armv7l_OpenGLES2.tar.xz.part03 cat Qt_5151_armv7l_OpenGLES2.tar.xz* > Qt5_OpenGLES2.tar.xz tar -xf Qt5_OpenGLES2.tar.xz -C / "