Created
November 17, 2022 06:33
-
-
Save runlevel5/936bd3dbe238172289cd3db2eb3375a6 to your computer and use it in GitHub Desktop.
This the patch to build RPM with static .a files
This file contains hidden or 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
Date: Thu, 17 Nov 2022 17:10:48 +1100 | |
Subject: [PATCH] Build static | |
--- | |
uuid.spec | 11 +++++++++-- | |
1 file changed, 9 insertions(+), 2 deletions(-) | |
diff --git a/uuid.spec b/uuid.spec | |
index c99d307..8f39927 100644 | |
--- a/uuid.spec | |
+++ b/uuid.spec | |
@@ -122,7 +122,7 @@ export PGSQL_NAME=$(pwd)/pgsql/libossp-uuid.so | |
export CFLAGS="$RPM_OPT_FLAGS" | |
export CXXFLAGS="$RPM_OPT_FLAGS" | |
%configure \ | |
- --disable-static \ | |
+ --enable-static \ | |
--without-perl \ | |
--without-php \ | |
--with-dce \ | |
@@ -142,8 +142,9 @@ popd | |
rm -rf $RPM_BUILD_ROOT | |
make install DESTDIR=$RPM_BUILD_ROOT | |
-rm -f $RPM_BUILD_ROOT%{_libdir}/*.la $RPM_BUILD_ROOT%{_libdir}/*.a | |
chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.so.*.*.* | |
+chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.la | |
+chmod 755 $RPM_BUILD_ROOT%{_libdir}/*.a | |
# Install the Perl modules. | |
pushd perl | |
@@ -176,6 +177,8 @@ popd | |
%{_libdir}/libossp-uuid.so.* | |
%{_mandir}/man1/* | |
%exclude %{_mandir}/man1/uuid-config.* | |
+%{_libdir}/libossp-uuid.la | |
+%{_libdir}/libossp-uuid.a | |
%files devel | |
%{_bindir}/uuid-config | |
@@ -187,6 +190,8 @@ popd | |
%files c++ | |
%{_libdir}/libossp-uuid++.so.* | |
+%{_libdir}/libossp-uuid++.a | |
+%{_libdir}/libossp-uuid++.la | |
%files c++-devel | |
%{_includedir}/uuid++.hh | |
@@ -200,6 +205,8 @@ popd | |
%files dce | |
%{_libdir}/libossp-uuid_dce.so.* | |
+%{_libdir}/libossp-uuid_dce.la | |
+%{_libdir}/libossp-uuid_dce.a | |
%files dce-devel | |
%{_includedir}/uuid_dce.h | |
-- | |
2.38.1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment