2015-11-02 11:33:13 +01:00
% with default - dm - run - dir % { _default_dm_run_dir }
% with default - run - dir % { _default_run_dir }
% with default - pid - dir % { _default_pid_dir }
% with default - locking - dir % { _default_locking_dir }
% with usrlibdir % { _libdir }
% enableif 1 fsadm
% with user
% with group
% with device - uid 0
% with device - gid 6
% with device - mode 0660
% enableif 1 pkgconfig
% enableif 1 cmdlib
% enableif 1 dmeventd
% enableif 1 write_install
2013-05-08 12:33:11 +02:00
% with udevdir % { _udevdir }
% enableif % { enable_cmirror } cmirrord
% enableif % { enable_udev } udev_sync
% enableif % { enable_profiling } profiling
2015-05-13 13:14:54 +02:00
% global enable_lvmpolld % ( if echo % { services } | grep - q lvmpolld ; then echo 1 ; else echo 0 ; fi )
% enableif % { enable_lvmpolld } lvmpolld
2015-03-05 14:00:44 -06:00
% global enable_lvmlockd % ( if echo % { services } | grep - q lvmlockd ; then echo 1 ; else echo 0 ; fi )
2015-07-07 14:54:57 +02:00
% if % { enable_lvmlockd }
2017-04-18 11:22:07 -05:00
% enableif % { enable_lvmlockd_dlm } lvmlockd - dlm
% enableif % { enable_lvmlockd_sanlock } lvmlockd - sanlock
2015-07-07 14:54:57 +02:00
% endif
2016-02-18 14:34:17 +01:00
% enableif % { enable_dbusd } dbus - service
2017-05-26 07:40:09 +02:00
% enableif % { enable_dbusd } notify - dbus
2017-03-28 21:35:46 +02:00
% enableif % { enable_dmfilemapd } dmfilemapd
2022-07-27 18:02:01 +02:00
% enableif % { enable_readline } readline
% enableif % { enable_editline } editline
2013-05-08 12:33:11 +02:00
% build
2015-11-02 11:33:13 +01:00
% configure % { configure_flags }
2013-05-08 12:33:11 +02:00
make % { ? _smp_mflags }
% { ? extra_build_commands }
% install
make install DESTDIR = $RPM_BUILD_ROOT
make install_system_dirs DESTDIR = $RPM_BUILD_ROOT
% if % { enable_systemd }
make install_systemd_units DESTDIR = $RPM_BUILD_ROOT
2015-09-09 15:59:32 +02:00
make install_systemd_generators DESTDIR = $RPM_BUILD_ROOT
2013-05-08 12:33:11 +02:00
make install_tmpfiles_configuration DESTDIR = $RPM_BUILD_ROOT
2015-05-13 13:14:54 +02:00
% else
make install_initscripts DESTDIR = $RPM_BUILD_ROOT
2013-05-08 12:33:11 +02:00
% endif
2014-06-27 01:24:47 +02:00
% if % { enable_testsuite }
make - C test install DESTDIR = $RPM_BUILD_ROOT
% endif
2013-05-08 12:33:11 +02:00
# when building an src.rpm from freestanding specfiles
test - e % { _sourcedir } / source . inc || cp source . inc build . inc packages . inc macros . inc % { _sourcedir }
% check
% { ? check_commands }
% clean
2013-12-15 21:12:06 +01:00
pwd
test - n rpm - no - clean || rm - rf $RPM_BUILD_ROOT