Parcourir la source

Add action for windows debug

tags/v1.8.0
Xerbo il y a 4 ans
Parent
révision
68c0360b29
4 fichiers modifiés avec 35 ajouts et 6 suppressions
  1. +30
    -0
      .github/workflows/win_debug.yml
  2. +3
    -3
      CMakeLists.txt
  3. +1
    -2
      build_windows.sh
  4. +1
    -1
      cmake/FindLibSndFile.cmake

+ 30
- 0
.github/workflows/win_debug.yml Voir le fichier

@@ -0,0 +1,30 @@
name: x86 Win Debug

on:
push:
branches:
- devel
env:
BUILD_TYPE: Debug

jobs:
build:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v2
- name: Install dependencies
# The user does not run as root
run: sudo apt install wget cmake make mingw-w64 git unzip libsndfile-dev

- name: Run build script
shell: bash
working-directory: ${{runner.workspace}}
run: cd $GITHUB_WORKSPACE && ./build_windows.sh

- name: Upload compilied binary
uses: actions/upload-artifact@v2
with:
name: Debug build
path: ${{runner.workspace}}/winbuild/aptdec-1.7.0.zip

+ 3
- 3
CMakeLists.txt Voir le fichier

@@ -37,16 +37,16 @@ set(CPACK_PACKAGE_VERSION "${PROJECT_VERSION}")
set(CPACK_PACKAGE_NAME "aptdec")
set(CPACK_PACKAGE_CONTACT "Xerbo (xerbo@protonmail.com)")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "NOAA APT satellite imagery decoder")
SET(CPACK_PACKAGE_DESCRIPTION "Aptdec is a FOSS program that decodes images transmitted by NOAA weather satellites. These satellites transmit constantly (among other things) medium resolution (4km/px) images of the earth over a analog mode called APT.")
set(CPACK_PACKAGE_DESCRIPTION "Aptdec is a FOSS program that decodes images transmitted by NOAA weather satellites. These satellites transmit constantly (among other things) medium resolution (4km/px) images of the earth over a analog mode called APT.")
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "amd64")
set(CPACK_DEBIAN_PACKAGE_SHLIBDEPS ON)

IF(NOT WIN32)
set(CPACK_GENERATOR "DEB")
set(CPACK_GENERATOR "DEB;TGZ")
set(CPACK_PACKAGE_FILE_NAME "${CPACK_PACKAGE_NAME}-${CPACK_PACKAGE_VERSION}.${CMAKE_SYSTEM_PROCESSOR}")

install(TARGETS aptdec DESTINATION "bin/")
install(DIRECTORY "${PROJECT_SOURCE_DIR}/palettes/" DESTINATION "lib/aptdec/palettes")
install(DIRECTORY "${PROJECT_SOURCE_DIR}/palettes/" DESTINATION "palettes/")
else()
#set(CPACK_GENERATOR "ZIP;NSIS")
set(CPACK_GENERATOR "ZIP")


+ 1
- 2
build_windows.sh Voir le fichier

@@ -32,12 +32,11 @@ if [ ! -d "libsndfile-1.0.29-win64" ]; then
wget https://github.com/erikd/libsndfile/releases/download/v1.0.29/libsndfile-1.0.29-win64.zip
unzip libsndfile-1.0.29-win64.zip
fi
cp "libsndfile-1.0.29-win64/bin/sndfile.dll" $TEMP_PATH/bin/libsndfile-1.dll
cp "libsndfile-1.0.29-win64/bin/sndfile.dll" $TEMP_PATH/bin/sndfile.dll
cp "libsndfile-1.0.29-win64/include/sndfile.h" $TEMP_PATH/include/sndfile.h

# Copy DLL's into root for CPack
cp $TEMP_PATH/bin/*.dll ../
mv ../libsndfile-1.dll ../sndfile.dll

# Build aptdec
mkdir -p winbuild && cd winbuild


+ 1
- 1
cmake/FindLibSndFile.cmake Voir le fichier

@@ -1,7 +1,7 @@
# Find libsndfile
FIND_PATH(LIBSNDFILE_INCLUDE_DIR sndfile.h)

SET(LIBSNDFILE_NAMES ${LIBSNDFILE_NAMES} sndfile libsndfile libsndfile-1)
SET(LIBSNDFILE_NAMES ${LIBSNDFILE_NAMES} sndfile libsndfile)
FIND_LIBRARY(LIBSNDFILE_LIBRARY NAMES ${LIBSNDFILE_NAMES} PATH)

IF(LIBSNDFILE_INCLUDE_DIR AND LIBSNDFILE_LIBRARY)


Chargement…
Annuler
Enregistrer