forked from SSSD/sssd-ci-containers
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
provision: move random.so into standalone rpm
To avoid pulling in build dependencies in minimal testing environment.
- Loading branch information
Showing
10 changed files
with
256 additions
and
181 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,3 @@ | ||
srpm: | ||
make -C ./src/rpms srpm | ||
[ -n "$(outdir)" ] && cp ./rpmbuild/SRPMS/* "$(outdir)" || : |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,35 @@ | ||
name: Build RPMs | ||
on: | ||
push: | ||
branches: | ||
- master | ||
pull_request: | ||
concurrency: | ||
group: ${{ github.workflow }}-${{ github.ref }} | ||
cancel-in-progress: true | ||
jobs: | ||
rpms: | ||
runs-on: ubuntu-latest | ||
container: | ||
image: fedora:38 | ||
permissions: | ||
contents: read | ||
steps: | ||
- uses: actions/checkout@v3 | ||
|
||
- name: Install dependencies | ||
shell: bash | ||
working-directory: ./src/rpms | ||
run: | | ||
dnf install -y rpm-build dnf-plugins-core | ||
dnf build-dep -y ./ci-sssd.spec | ||
- name: Build srpm | ||
shell: bash | ||
working-directory: ./src/rpms | ||
run: make srpm | ||
|
||
- name: Build rpms | ||
shell: bash | ||
working-directory: ./src/rpms | ||
run: make rpms |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1 @@ | ||
../../../../rpms/random.c |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
prep: | ||
mkdir -p $(PWD)/rpmbuild/BUILD | ||
mkdir -p $(PWD)/rpmbuild/RPMS | ||
mkdir -p $(PWD)/rpmbuild/SOURCES | ||
mkdir -p $(PWD)/rpmbuild/SPECS | ||
mkdir -p $(PWD)/rpmbuild/SRPMS | ||
cp random.c $(PWD)/rpmbuild/SOURCES | ||
cp ci-sssd.spec $(PWD)/rpmbuild/SPECS | ||
|
||
srpm: prep | ||
rpmbuild --define "_topdir $(PWD)/rpmbuild" -bs ci-sssd.spec | ||
|
||
rpms: prep | ||
rpmbuild --define "_topdir $(PWD)/rpmbuild" -ba ci-sssd.spec | ||
|
||
clean: | ||
rm -fr $(PWD)/rpmbuild |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
Name: ci-sssd | ||
Version: 1 | ||
Release: 1%{?dist} | ||
Summary: SSSD CI Packages | ||
URL: https://github.com/SSSD/sssd-ci-containers | ||
|
||
License: GPLv3+ | ||
Source0: random.c | ||
|
||
BuildRequires: gcc | ||
BuildRequires: openssl-devel | ||
|
||
%description | ||
SSSD CI Packages. For testing purpose only. | ||
|
||
%prep | ||
|
||
%build | ||
gcc -fPIC -shared -o random.so %{SOURCE0} -lcrypto | ||
|
||
%install | ||
mkdir -p %{buildroot}/opt | ||
cp random.so %{buildroot}/opt/random.so | ||
|
||
%package random | ||
Summary: random.so for passkey testing. | ||
|
||
%description random | ||
random.so for passkey testing. | ||
|
||
%files random | ||
/opt/random.so | ||
|
||
%changelog | ||
* Thu Jul 20 2023 SSSD Team <[email protected]> - 1.0.0-1 | ||
- Test package release. |
Oops, something went wrong.