Skip to content

Commit 0583808

Browse files
committed
Our buildsystem macros are just examples, don't actually ship them
Split the examples into a separate macro file only used by the test-suite.
1 parent cd06d34 commit 0583808

File tree

3 files changed

+11
-10
lines changed

3 files changed

+11
-10
lines changed

macros.in

-10
Original file line numberDiff line numberDiff line change
@@ -1356,16 +1356,6 @@ end
13561356
%buildsystem_default_prep() %autosetup -p1 %*
13571357
%buildsystem_default_clean() %{__rm} -rf %{buildroot}
13581358

1359-
# Example buildsystem for autotools
1360-
%buildsystem_autotools_conf() %configure %*
1361-
%buildsystem_autotools_build() %make_build %*
1362-
%buildsystem_autotools_install() %make_install %*
1363-
1364-
# Example buildsystem for cmake
1365-
%buildsystem_cmake_conf() cmake %* -B __rpmbuild -S .
1366-
%buildsystem_cmake_build() cmake --build __rpmbuild %{?smp_mflags} %{?verbose:-v} -- %*
1367-
%buildsystem_cmake_install() DESTDIR=${RPM_BUILD_ROOT} cmake --install __rpmbuild %{?verbose:-v} %*
1368-
13691359
# \endverbatim
13701360
#*/
13711361

tests/data/macros.buildsystem

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# Example buildsystem for autotools
2+
%buildsystem_autotools_conf() %configure %*
3+
%buildsystem_autotools_build() %make_build %*
4+
%buildsystem_autotools_install() %make_install %*
5+
6+
# Example buildsystem for cmake
7+
%buildsystem_cmake_conf() cmake %* -B __rpmbuild -S .
8+
%buildsystem_cmake_build() cmake --build __rpmbuild %{?smp_mflags} %{?verbose:-v} -- %*
9+
%buildsystem_cmake_install() DESTDIR=${RPM_BUILD_ROOT} cmake --install __rpmbuild %{?verbose:-v} %*

tests/rpmbuild.at

+2
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ AT_SETUP([rpmbuild -b buildsystem])
4848
AT_KEYWORDS([build])
4949
RPMDB_INIT
5050

51+
cp "${RPMTEST}/data/macros.buildsystem" "${RPMTEST}/${RPM_CONFIGDIR_PATH}/macros.d/"
52+
5153
RPMTEST_CHECK([
5254
runroot rpmbuild -bb \
5355
--define "_prefix /usr" \

0 commit comments

Comments
 (0)