Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

WIP: Added support for Packit build #13

Closed
wants to merge 5 commits into from
Closed
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
2 changes: 1 addition & 1 deletion .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ env:

jobs:
build:
# The CMake configure and build commands are platform agnostic and should work equally
# The CMake configure and build commands are platform-agnostic and should work equally
# well on Windows or Mac. You can convert this to a matrix build if you need
# cross-platform coverage.
# See: https://docs.github.com/en/free-pro-team@latest/actions/learn-github-actions/managing-complex-workflows#using-a-build-matrix
Expand Down
19 changes: 19 additions & 0 deletions .packit.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
upstream_package_name: daemon
downstream_package_name: daemon
specfile_path: daemon.spec

srpm_build_deps:
- tito
- gcc
- git-core
- make
- rpm-build
- 'pkgconfig(systemd)'

jobs:
- job: copr_build
trigger: pull_request
targets:
- centos-stream-9
- centos-stream-10
- fedora-all
8 changes: 0 additions & 8 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,6 @@ endif ()
# Define project name
project (Daemon C)

# The version number
set (${PROJECT_NAME}_VERSION_MAJOR 0)
set (${PROJECT_NAME}_VERSION_MINOR 1)
set (${PROJECT_NAME}_PATCH_LEVEL 0)

set (${PROJECT_NAME}_VERSION
"${${PROJECT_NAME}_VERSION_MAJOR}.${${PROJECT_NAME}_VERSION_MINOR}")

# Set up directory with 3rd party cmake modules
set (CMAKE_MODULE_PATH
${CMAKE_MODULE_PATH} "${CMAKE_SOURCE_DIR}/build_files/cmake/modules/")
Expand Down
18 changes: 15 additions & 3 deletions daemon.spec
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@


Name: daemon
Version: 0.1
Version: 0.2
Release: 1%{?dist}
Summary: Example of daemon

Expand Down Expand Up @@ -46,7 +46,7 @@ exit 0
%build

# We have to use build type "Debug" to be able to create all variants of
# rpm packages (debuginfo, debugsource). The normal rpm is stripped from
# rpm packages (debuginfo, debug source). The normal rpm is stripped from
# debug information. Following macro just run cmake and it generates Makefile
%cmake -DCMAKE_BUILD_TYPE="Debug"

Expand Down Expand Up @@ -88,9 +88,21 @@ rm -rf $RPM_BUILD_ROOT
# This is section, where you should describe all important changes
# in RPM
%changelog
* Mon Jan 22 2024 Jiri Hnidek <[email protected]>
- Add initial support for Packit
- Updated version of daemon to 0.2

* Tue Oct 24 2023 Jiri Hnidek <[email protected]>
- Fix building of RPM on COPR

* Wed Sep 29 2021 Jiri Hnidek <[email protected]>
- Use non-root user for runnig daemon

* Mon Sep 27 2021 Jiri Hnidek <[email protected]>
- Use GitHub Actions for building RPM

* Fri Aug 27 2021 Jiri Hnidek <[email protected]>
- new package built with tito
- RPM package built with tito

* Fri Aug 27 2021 Jiri Hnidek <[email protected]>
- Added first version of daemon.spec