mirror of
https://github.com/scylladb/scylladb.git
synced 2026-06-01 12:36:56 +00:00
Since systemd unit can override parameters using drop-in unit, we don't need mustache template for them. Also, drop --disttype and --target options on install.sh since it does not required anymore, introduce --sysconfdir instead for non-redhat distributions.
61 lines
2.1 KiB
Plaintext
Executable File
61 lines
2.1 KiB
Plaintext
Executable File
#!/usr/bin/make -f
|
|
|
|
export PYBUILD_DISABLE=1
|
|
jobs := $(shell echo $$DEB_BUILD_OPTIONS | sed -r "s/.*parallel=([0-9]+).*/-j\1/")
|
|
{{#housekeeping}}
|
|
install_arg := --housekeeping
|
|
{{/housekeeping}}
|
|
{{^housekeeping}}
|
|
install_arg :=
|
|
{{/housekeeping}}
|
|
|
|
override_dh_auto_configure:
|
|
|
|
override_dh_auto_build:
|
|
|
|
override_dh_auto_clean:
|
|
|
|
override_dh_auto_install:
|
|
dh_auto_install
|
|
./install.sh --root "$(CURDIR)/debian/{{product}}-conf" $(install_arg) --sysconfdir "/etc/default" --pkg "conf"
|
|
./install.sh --root "$(CURDIR)/debian/{{product}}-kernel-conf" $(install_arg) --sysconfdir "/etc/default" --pkg "kernel-conf"
|
|
./install.sh --root "$(CURDIR)/debian/{{product}}-server" $(install_arg) --sysconfdir "/etc/default" --pkg "server"
|
|
{{#housekeeping}}
|
|
# XXX: since housekeeping.cfg is mistakenly belongs to different package
|
|
# in .rpm/.deb, we need this workaround to make package upgradable
|
|
mv $(CURDIR)/debian/{{product}}-conf/etc/scylla.d/housekeeping.cfg $(CURDIR)/debian/{{product}}-server/etc/scylla.d/housekeeping.cfg
|
|
rm -rf $(CURDIR)/debian/{{product}}-conf/etc/scylla.d
|
|
{{/housekeeping}}
|
|
# don't use default sysconfig file, use Debian version
|
|
cp dist/debian/sysconfig/scylla-housekeeping $(CURDIR)/debian/{{product}}-server/etc/default/
|
|
|
|
override_dh_installinit:
|
|
{{#scylla}}
|
|
dh_installinit --no-start
|
|
{{/scylla}}
|
|
{{^scylla}}
|
|
dh_installinit --no-start --name scylla-server
|
|
{{/scylla}}
|
|
dh_installinit --no-start --name scylla-housekeeping-daily
|
|
dh_installinit --no-start --name scylla-housekeeping-restart
|
|
dh_installinit --no-start --name scylla-fstrim
|
|
dh_installinit --no-start --name node-exporter
|
|
|
|
override_dh_strip:
|
|
# The binaries (ethtool...patchelf) don't pass dh_strip after going through patchelf. Since they are
|
|
# already stripped, nothing is lost if we exclude them, so that's what we do.
|
|
dh_strip -Xlibprotobuf.so.15 -Xld.so -Xethtool -Xgawk -Xgzip -Xhwloc-calc -Xhwloc-distrib -Xifconfig -Xlscpu -Xnetstat -Xpatchelf --dbg-package={{product}}-server-dbg
|
|
|
|
override_dh_makeshlibs:
|
|
|
|
override_dh_shlibdeps:
|
|
|
|
override_dh_fixperms:
|
|
dh_fixperms
|
|
chmod 755 $(CURDIR)/debian/{{product}}-server/opt/scylladb/libreloc/ld.so
|
|
|
|
override_dh_strip_nondeterminism:
|
|
|
|
%:
|
|
dh $@
|