From 40fb1869674a397482a45cbaa66a1491361ea502 Mon Sep 17 00:00:00 2001 From: YellowJacketLinux Date: Sat, 6 May 2023 13:36:41 -0700 Subject: [PATCH] add rpm macro file --- SOURCES/rpm-macros-makeca | 6 ++++++ SPECS/make-ca.spec | 16 ++++++++++++++-- 2 files changed, 20 insertions(+), 2 deletions(-) create mode 100644 SOURCES/rpm-macros-makeca diff --git a/SOURCES/rpm-macros-makeca b/SOURCES/rpm-macros-makeca new file mode 100644 index 0000000..83468b8 --- /dev/null +++ b/SOURCES/rpm-macros-makeca @@ -0,0 +1,6 @@ +# Macros related to make-ca certificates +%_ssldir /etc/ssl +%_pkitls /etc/pki/tls +%cabundle %{_pkitls}/certs/ca-bundle.crt +%email_cabundle %{_pkitls}/certs/email-ca-bundle.crt +%objsign_cabundle %{_pkitls}/certs/objsign-ca-bundle.crt diff --git a/SPECS/make-ca.spec b/SPECS/make-ca.spec index 4144a79..6117634 100644 --- a/SPECS/make-ca.spec +++ b/SPECS/make-ca.spec @@ -1,8 +1,12 @@ %global githubv 20230430 +%if 0%{!?__curl:1} == 1 +%global __curl %{_bindir}/curl +%endif + Name: make-ca Version: %{githubv} -Release: %{?repo}0.rc1%{?dist} +Release: %{?repo}0.rc2%{?dist} Summary: Manage PKI configuration BuildArch: noarch @@ -10,9 +14,10 @@ Group: System Environment/Utilities License: MIT and GPL-3.0-only URL: https://github.com/YellowJacketLinux/make-ca Source0: https://github.com/YellowJacketLinux/make-ca/archive/refs/tags/%{githubv}.tar.gz +Source1: rpm-macros-makeca Requires: libressl -Requires: curl +Requires: %{__curl} Requires: nss Requires: p11-kit Requires(post): libressl @@ -42,6 +47,9 @@ modified for YellowJacket GNU/Linux (YJL). %install make install DESTDIR=%{buildroot} +mkdir -p %{buildroot}/usr/lib/rpm/macros.d +install -m644 %{SOURCE1} %{buildroot}%{_prefix}/lib/rpm/macros.d/macros.makeca + %post if [ $1 == 1 ]; then %{_sbindir}/make-ca -f -C %{_sysconfdir}/make-ca/certdata-dist.txt \ @@ -59,6 +67,7 @@ fi %dir %{_libexecdir}/make-ca %attr(0700,root,root) %{_libexecdir}/make-ca/copy-trust-modifications %attr(0755,root,root) %{_sbindir}/make-ca +%attr(0644,root,root) %{_prefix}/lib/rpm/macros.d/macros.makeca %attr(0644,root,root) %{_mandir}/man8/make-ca.8* %license LICENSE LICENSE.GPLv3 LICENSE.MIT LICENSE.MPLv2 %doc CHANGELOG* README.md LICENSE LICENSE.GPLv3 LICENSE.MIT LICENSE.MPLv2 @@ -66,5 +75,8 @@ fi %changelog +* Sat May 06 2023 Michael A. Peters - 20230430-0.rc2 +- Add RPM macro file + * Sun Apr 30 2023 Michael A. Peters - 20230430-0.rc1 - Initial spec file for YJL (RPM bootstrapping LFS/BLFS 11.3)