diff --git a/.gitea/workflows/build-windows.yml b/.gitea/workflows/build-windows.yml index 6661fed..f7c9bda 100644 --- a/.gitea/workflows/build-windows.yml +++ b/.gitea/workflows/build-windows.yml @@ -63,6 +63,15 @@ jobs: echo "SHORT_SHA=${SHORT_SHA}" >> $GITHUB_ENV mv Argyll_V*_win64_exe.zip "Argyll_${TAG}_${SHORT_SHA}_win64_exe.zip" + - name: Verify Package Contents + run: | + ZIP_FILE=$(ls Argyll_*_win64_exe.zip) + echo "Verifying contents of ${ZIP_FILE}..." + unzip -l "${ZIP_FILE}" | grep "usb/ArgyllCMS.inf" + unzip -l "${ZIP_FILE}" | grep "usb/bin/amd64/libusb0.sys" + unzip -l "${ZIP_FILE}" | grep "doc/ArgyllDoc.html" + unzip -l "${ZIP_FILE}" | grep "ReadMe.txt" + - name: Upload Artifact uses: actions/upload-artifact@v3 with: diff --git a/.github/workflows/build-windows.yml b/.github/workflows/build-windows.yml index 90495b5..711785b 100644 --- a/.github/workflows/build-windows.yml +++ b/.github/workflows/build-windows.yml @@ -65,6 +65,15 @@ jobs: echo "SHORT_SHA=${SHORT_SHA}" >> $GITHUB_ENV mv Argyll_V*_win64_exe.zip "Argyll_${TAG}_${SHORT_SHA}_win64_exe.zip" + - name: Verify Package Contents + run: | + ZIP_FILE=$(ls Argyll_*_win64_exe.zip) + echo "Verifying contents of ${ZIP_FILE}..." + unzip -l "${ZIP_FILE}" | grep "usb/ArgyllCMS.inf" + unzip -l "${ZIP_FILE}" | grep "usb/bin/amd64/libusb0.sys" + unzip -l "${ZIP_FILE}" | grep "doc/ArgyllDoc.html" + unzip -l "${ZIP_FILE}" | grep "ReadMe.txt" + - name: Upload Artifact uses: actions/upload-artifact@v4 with: diff --git a/makepackagebin.sh b/makepackagebin.sh index 30da71e..f7beac1 100755 --- a/makepackagebin.sh +++ b/makepackagebin.sh @@ -167,13 +167,21 @@ fi rm -rf $TOPDIR mkdir $TOPDIR +# Ensure catalog copies exist if needed for Windows packaging +if [ -d usb ] ; then + if [ -f usb/ArgyllCMS.cat ] ; then + [ ! -f usb/ArgyllCMS_x64.cat ] && cp usb/ArgyllCMS.cat usb/ArgyllCMS_x64.cat + [ ! -f usb/ArgyllCMS_arm64.cat ] && cp usb/ArgyllCMS.cat usb/ArgyllCMS_arm64.cat + fi +fi + # Collect the names of all the files that we're going to package -unset topfiles; for i in `cat binfiles`; do topfiles="$topfiles ${i}"; done -unset docfiles; for i in `cat doc/afiles`; do docfiles="$docfiles doc/${i}"; done +unset topfiles; for i in `tr -d '\r' < binfiles`; do topfiles="$topfiles ${i}"; done +unset docfiles; for i in `tr -d '\r' < doc/afiles`; do docfiles="$docfiles doc/${i}"; done unset usbfiles; for j in ${USBDIRS}; do if [ ${j} ]; then - for i in `cat ${j}/${USBBINFILES}`; do usbfiles="$usbfiles ${j}/${i}"; done + for i in `tr -d '\r' < ${j}/${USBBINFILES}`; do usbfiles="$usbfiles ${j}/${i}"; done fi done @@ -183,16 +191,16 @@ allfiles="${topfiles} bin/* ref/* ${docfiles} ${usbfiles}" for i in ${allfiles}; do path=${i%/*} # extract path without filename file=${i##*/} # extract filename - if [ $path = $i ] ; then + if [ "$path" = "$i" ] ; then path= fi - if [ X$path != "X" ] ; then - mkdir -p $TOPDIR/${path} + if [ X"$path" != "X" ] ; then + mkdir -p "$TOPDIR/${path}" fi - if [ X${file} = "Xafiles" ] ; then + if [ X"${file}" = "Xafiles" ] ; then continue fi - cp $i $TOPDIR/$i + cp "$i" "$TOPDIR/$i" || { echo "Failed to copy $i to $TOPDIR/$i"; exit 1; } done # Create the package diff --git a/usb/ArgyllCMS_arm64.cat b/usb/ArgyllCMS_arm64.cat new file mode 100644 index 0000000..a1c607c Binary files /dev/null and b/usb/ArgyllCMS_arm64.cat differ diff --git a/usb/ArgyllCMS_x64.cat b/usb/ArgyllCMS_x64.cat new file mode 100644 index 0000000..a1c607c Binary files /dev/null and b/usb/ArgyllCMS_x64.cat differ