Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .devcontainer
Submodule .devcontainer added at 92bded
19 changes: 19 additions & 0 deletions .github/workflows/xpbuild.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
name: Build
on:
push:
branches: [ "dev" ]
pull_request:
branches: [ "dev" ]
workflow_dispatch:
jobs:
linux:
permissions:
contents: read
pull-requests: write
packages: write
uses: externpro/externpro/.github/workflows/build-linux.yml@25.06.3
with:
artifact-pattern: "${{ github.event.repository.name }}-*.rpm"
cmake-workflow-preset: LinuxRelease
buildpro-images: '["rocky9-gcc13"]'
secrets: inherit
20 changes: 20 additions & 0 deletions .github/workflows/xprelease.yml
Original file line number Diff line number Diff line change
@@ -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.06.3
with:
workflow_run_url: ${{ github.event.inputs.workflow_run_url }}
artifact_pattern: "*.rpm"
permissions:
contents: write
id-token: write
attestations: write
secrets: inherit
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
# externpro
.env
_bld*/
docker-compose.override.yml
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule ".devcontainer"]
path = .devcontainer
url = https://github.com/externpro/externpro
30 changes: 30 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
cmake_minimum_required(VERSION 3.31)
set(CMAKE_BUILD_TYPE "Release" CACHE STRING "Build configuration")
set(CMAKE_PROJECT_TOP_LEVEL_INCLUDES .devcontainer/cmake/xproinc.cmake)
project(cmake-pkg VERSION 3.31.6 LANGUAGES CXX)
# https://github.com/Kitware/CMake/releases/tag/v3.31.6
# https://github.com/Kitware/CMake/releases/download/v3.31.6/cmake-3.31.6-linux-x86_64.tar.gz
# https://github.com/Kitware/CMake/releases/download/v3.31.6/cmake-3.31.6-linux-aarch64.tar.gz
set(sha_aarch64 b4cc788d63112b2749b40627e719eb5d3b8ed8f00c36d77189f4019cfe64bc9e)
set(sha_x86_64 5a1133ff103c71eb5120e2cc3de922733e7d8a26a98ae716397e8676adb367bf)
set(REPO https://github.com/Kitware/CMake)
string(TOLOWER ${CMAKE_SYSTEM_NAME} os)
if(CMAKE_SYSTEM_PROCESSOR MATCHES "^(x86_64|amd64|AMD64)$")
set(arch "x86_64")
elseif(CMAKE_SYSTEM_PROCESSOR MATCHES "^(aarch64|arm64|ARM64)$")
set(arch "aarch64")
endif()
set(url ${REPO}/releases/download/v${PROJECT_VERSION}/cmake-${PROJECT_VERSION}-${os}-${arch}.tar.gz)
set(opt DOWNLOAD_EXTRACT_TIMESTAMP true)
include(FetchContent)
FetchContent_Declare(cmake ${opt} URL ${url} URL_HASH SHA256=${sha_${arch}})
FetchContent_MakeAvailable(cmake)
install(DIRECTORY ${cmake_SOURCE_DIR}/ DESTINATION . USE_SOURCE_PERMISSIONS)
set(CPACK_GENERATOR RPM)
set(CPACK_RPM_PACKAGE_ARCHITECTURE ${arch})
# https://github.com/externpro/externpro/issues/53
set(CPACK_RPM_SPEC_MORE_DEFINE "%define _build_id_links none")
set(CPACK_PACKAGING_INSTALL_PREFIX "/usr/local")
set(CPACK_PACKAGE_VERSION v${PROJECT_VERSION})
set(CPACK_SYSTEM_NAME ${os}-${arch})
include(CPack)
6 changes: 6 additions & 0 deletions CMakePresets.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"version": 8,
"include": [
".devcontainer/cmake/presets/xpLinuxNinja.json"
]
}
16 changes: 16 additions & 0 deletions CMakePresetsBase.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
{
"version": 8,
"configurePresets": [
{
"name": "config-base",
"hidden": true,
"binaryDir": "${sourceDir}/_bld-${presetName}"
}
],
"buildPresets": [
{
"name": "build-base",
"hidden": true
}
]
}
1 change: 1 addition & 0 deletions docker-compose.sh
1 change: 1 addition & 0 deletions docker-compose.yml