From 8382be58731d9c7b73d2c98fc8a634969c19daff Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 12:48:13 -0600 Subject: [PATCH 01/10] git submodule add https://github.com/externpro/externpro .devcontainer --- .devcontainer | 1 + .gitmodules | 3 +++ 2 files changed, 4 insertions(+) create mode 160000 .devcontainer create mode 100644 .gitmodules diff --git a/.devcontainer b/.devcontainer new file mode 160000 index 0000000..6c07d01 --- /dev/null +++ b/.devcontainer @@ -0,0 +1 @@ +Subproject commit 6c07d011aaa0e1f95b958fbd4ada86172634bb7b diff --git a/.gitmodules b/.gitmodules new file mode 100644 index 0000000..18932ab --- /dev/null +++ b/.gitmodules @@ -0,0 +1,3 @@ +[submodule ".devcontainer"] + path = .devcontainer + url = https://github.com/externpro/externpro From 555d9f75d1bb38d187104e5ab809ac7894d0b127 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 12:51:00 -0600 Subject: [PATCH 02/10] docker-compose links --- docker-compose.sh | 1 + docker-compose.yml | 1 + 2 files changed, 2 insertions(+) create mode 120000 docker-compose.sh create mode 120000 docker-compose.yml diff --git a/docker-compose.sh b/docker-compose.sh new file mode 120000 index 0000000..85f182f --- /dev/null +++ b/docker-compose.sh @@ -0,0 +1 @@ +.devcontainer/compose.pro.sh \ No newline at end of file diff --git a/docker-compose.yml b/docker-compose.yml new file mode 120000 index 0000000..46c1f89 --- /dev/null +++ b/docker-compose.yml @@ -0,0 +1 @@ +.devcontainer/compose.bld.yml \ No newline at end of file From cdc679957cc8765e0f2aa74055e8acff04cbd310 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 12:51:52 -0600 Subject: [PATCH 03/10] externpro github/workflows @25.05.1 cp .devcontainer/.github/wf-templates/xp*.yml .github/workflows --- .github/workflows/xpbuild.yml | 30 ++++++++++++++++++++++++++++++ .github/workflows/xprelease.yml | 20 ++++++++++++++++++++ 2 files changed, 50 insertions(+) create mode 100644 .github/workflows/xpbuild.yml create mode 100644 .github/workflows/xprelease.yml diff --git a/.github/workflows/xpbuild.yml b/.github/workflows/xpbuild.yml new file mode 100644 index 0000000..151d481 --- /dev/null +++ b/.github/workflows/xpbuild.yml @@ -0,0 +1,30 @@ +name: Build +on: + push: + branches: [ "dev" ] + pull_request: + branches: [ "dev" ] + workflow_dispatch: +jobs: + linux: + uses: externpro/externpro/.github/workflows/build-linux.yml@25.05.1 + with: + cmake-workflow-preset: Linux + runon: ubuntu-latest + secrets: inherit + linux-arm64: + uses: externpro/externpro/.github/workflows/build-linux.yml@25.05.1 + with: + cmake-workflow-preset: Linux + runon: ubuntu-24.04-arm + secrets: inherit + macos: + uses: externpro/externpro/.github/workflows/build-macos.yml@25.05.1 + with: + cmake-workflow-preset: Darwin + secrets: inherit + windows: + uses: externpro/externpro/.github/workflows/build-windows.yml@25.05.1 + with: + cmake-workflow-preset: Windows + secrets: inherit diff --git a/.github/workflows/xprelease.yml b/.github/workflows/xprelease.yml new file mode 100644 index 0000000..f868a82 --- /dev/null +++ b/.github/workflows/xprelease.yml @@ -0,0 +1,20 @@ +name: Release +on: + workflow_dispatch: + inputs: + workflow_run_url: + description: 'URL of the workflow run containing artifacts to upload (e.g., https://github.com/owner/repo/actions/runs/123456789)' + required: true + type: string +jobs: + # Upload build artifacts as release assets + release-from-build: + uses: externpro/externpro/.github/workflows/release-from-build.yml@25.05.1 + with: + workflow_run_url: ${{ github.event.inputs.workflow_run_url }} + artifact_pattern: "*.tar.xz" + permissions: + contents: write + id-token: write + attestations: write + secrets: inherit From 8384b5cc8666a6de8f2ee7b2f3a1d3b52dece21c Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 12:52:40 -0600 Subject: [PATCH 04/10] add CMakePresets --- CMakePresets.json | 8 ++++++++ CMakePresetsBase.json | 10 ++++++++++ 2 files changed, 18 insertions(+) create mode 100644 CMakePresets.json create mode 100644 CMakePresetsBase.json diff --git a/CMakePresets.json b/CMakePresets.json new file mode 100644 index 0000000..f82cfdd --- /dev/null +++ b/CMakePresets.json @@ -0,0 +1,8 @@ +{ + "version": 8, + "include": [ + ".devcontainer/cmake/presets/xpLinuxNinja.json", + ".devcontainer/cmake/presets/xpDarwinNinja.json", + ".devcontainer/cmake/presets/xpWindowsVs2022.json" + ] +} diff --git a/CMakePresetsBase.json b/CMakePresetsBase.json new file mode 100644 index 0000000..09653d8 --- /dev/null +++ b/CMakePresetsBase.json @@ -0,0 +1,10 @@ +{ + "version": 8, + "configurePresets": [ + { + "name": "config-base", + "hidden": true, + "binaryDir": "${sourceDir}/_bld-${presetName}" + } + ] +} From f29546abfd0c74df6d2750dcd69265dbcd761843 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 12:53:20 -0600 Subject: [PATCH 05/10] gitignore: add externpro ignores --- .gitignore | 3 +++ 1 file changed, 3 insertions(+) create mode 100644 .gitignore diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1fc17fa --- /dev/null +++ b/.gitignore @@ -0,0 +1,3 @@ +.env +_bld*/ +docker-compose.override.yml From 3b7c130d39b49938ec7ad8e63bc24427e6f59864 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 13:22:39 -0600 Subject: [PATCH 06/10] add .gitattributes --- .gitattributes | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) create mode 100644 .gitattributes diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..6b484ee --- /dev/null +++ b/.gitattributes @@ -0,0 +1,78 @@ +CMakeLists.txt text eol=lf +Dockerfile text eol=lf +.gitattributes text eol=lf +*.c text eol=lf +*.cfg text eol=lf +*.cls text eol=lf +*.cmake text eol=lf +*.conf text eol=lf +*.cpp text eol=lf +*.cs text eol=lf +*.css text eol=lf +*.csv text eol=lf +*.cu text eol=lf +*.cuh text eol=lf +*.cuhpp text eol=lf +*.cuhpp linguist-detectable +*.cuhpp linguist-language=C++ +*.dae text eol=lf +*.dockerfile text eol=lf +*.dot text eol=lf +*.eps text eol=lf +*.fbs text eol=lf +*.h text eol=lf +*.h.in text eol=lf +*.hpp text eol=lf +*.hpp.in text eol=lf +*.hrc text eol=lf +*.html text eol=lf +*.js text eol=lf +*.json text eol=lf +*.less text eol=lf +*.lua text eof=lf +*.md text eol=lf +*.pjd text eol=lf +*.proto text eol=lf +*.rc text eol=lf +*.rch text eol=lf +*.scss text eol=lf +*.sh text eol=lf +*.svg text eol=lf +*.tex text eol=lf +*.ts text eol=lf +*.txt text eol=lf +*.type text eol=lf +*.xml text eol=lf +*.xpm text eol=lf +*.xsd text eol=lf +*.yml text eol=lf +.*rc text eol=lf +#################### +*.csproj.in text eol=crlf +*.filters text eol=crlf +*.m text eol=crlf +*.resx text eol=crlf +*.rst text eol=crlf +*.sln text eol=crlf +*.sql text eol=crlf +*.vcproj text eol=crlf +*.vcxproj text eol=crlf +#################### +*.bin binary +*.bmp binary +*.db binary +*.doc binary +*.eap binary +*.gif binary +*.ico binary +*.jpeg binary +*.jpg binary +*.mp3 binary +*.ntf binary +*.pdf binary +*.png binary +*.rtf binary +*.vsd binary +*.xcf binary +*.xlsx binary +*.zip binary From c3b7cf7e32276b7765ea23ed10b81b58313ab73e Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 13:27:20 -0600 Subject: [PATCH 07/10] CMakePresetsBase: add cacheVariables XP_NAMESPACE --- CMakePresetsBase.json | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/CMakePresetsBase.json b/CMakePresetsBase.json index 09653d8..565061f 100644 --- a/CMakePresetsBase.json +++ b/CMakePresetsBase.json @@ -4,7 +4,10 @@ { "name": "config-base", "hidden": true, - "binaryDir": "${sourceDir}/_bld-${presetName}" + "binaryDir": "${sourceDir}/_bld-${presetName}", + "cacheVariables": { + "XP_NAMESPACE": "xpro" + } } ] } From 5502c7f90f95b107cbc9d49db912871e81dec294 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 13:45:48 -0600 Subject: [PATCH 08/10] xpbuild: cmake-workflow-preset Release --- .github/workflows/xpbuild.yml | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/xpbuild.yml b/.github/workflows/xpbuild.yml index 151d481..fb55758 100644 --- a/.github/workflows/xpbuild.yml +++ b/.github/workflows/xpbuild.yml @@ -9,22 +9,22 @@ jobs: linux: uses: externpro/externpro/.github/workflows/build-linux.yml@25.05.1 with: - cmake-workflow-preset: Linux + cmake-workflow-preset: LinuxRelease runon: ubuntu-latest secrets: inherit linux-arm64: uses: externpro/externpro/.github/workflows/build-linux.yml@25.05.1 with: - cmake-workflow-preset: Linux + cmake-workflow-preset: LinuxRelease runon: ubuntu-24.04-arm secrets: inherit macos: uses: externpro/externpro/.github/workflows/build-macos.yml@25.05.1 with: - cmake-workflow-preset: Darwin + cmake-workflow-preset: DarwinRelease secrets: inherit windows: uses: externpro/externpro/.github/workflows/build-windows.yml@25.05.1 with: - cmake-workflow-preset: Windows + cmake-workflow-preset: WindowsRelease secrets: inherit From 0b05bd18cf328c7d8cb72dd1bedde655eb5d55be Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 13:46:18 -0600 Subject: [PATCH 09/10] externpro dependency provider --- CMakeLists.txt | 1 + 1 file changed, 1 insertion(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 720f399..8ff13e8 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1,4 +1,5 @@ cmake_minimum_required(VERSION 3.31) +set(CMAKE_PROJECT_TOP_LEVEL_INCLUDES .devcontainer/cmake/xproinc.cmake) project(wxInclude) include(GNUInstallDirs) include(xpflags) From 2f1e7ca38967e424d31518aa7a427b7a02b97991 Mon Sep 17 00:00:00 2001 From: Scott M Anderson Date: Mon, 29 Sep 2025 13:47:24 -0600 Subject: [PATCH 10/10] externpro devel package --- CMakeLists.txt | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 8ff13e8..aebd62e 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -6,18 +6,22 @@ include(xpflags) xpFindPkg(PKGS boost) add_executable(${CMAKE_PROJECT_NAME} wxInclude.cpp) target_link_libraries(${CMAKE_PROJECT_NAME} PRIVATE Boost::filesystem Boost::program_options Boost::timer) -string(TOLOWER ${PROJECT_NAME} prj) -install(TARGETS ${CMAKE_PROJECT_NAME} EXPORT ${prj}-targets - RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} - LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} - ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} - ) +set(exe ${CMAKE_PROJECT_NAME}) if(DEFINED XP_NAMESPACE) set(nameSpace NAMESPACE ${XP_NAMESPACE}::) + string(PREPEND exe "${XP_NAMESPACE}::") endif() if(NOT DEFINED XP_INSTALL_CMAKEDIR) set(XP_INSTALL_CMAKEDIR ${CMAKE_INSTALL_DATADIR}/cmake) endif() -install(EXPORT ${prj}-targets DESTINATION ${XP_INSTALL_CMAKEDIR} ${nameSpace}) +string(TOLOWER ${PROJECT_NAME} prj) +set(targetsFile ${prj}-targets) +xpPackageDevel(TARGETS_FILE ${targetsFile} EXE ${exe}) +install(TARGETS ${CMAKE_PROJECT_NAME} EXPORT ${targetsFile} + RUNTIME DESTINATION ${CMAKE_INSTALL_BINDIR} + LIBRARY DESTINATION ${CMAKE_INSTALL_LIBDIR} + ARCHIVE DESTINATION ${CMAKE_INSTALL_LIBDIR} + ) +install(EXPORT ${targetsFile} DESTINATION ${XP_INSTALL_CMAKEDIR} ${nameSpace}) add_executable(decompressor decompress.cpp) target_link_libraries(decompressor PRIVATE Boost::filesystem Boost::iostreams)