We are trying to create a deb package, to install and auto-start a couple of monitoring scripts we have.
Here is the rules file:
#!/usr/bin/make -f
%:
dh $@ --with=systemd --with=python2
override_dh_installinit:
dh_systemd_enable -pmonitor --name=monitor monitor.service
dh_installinit -pmonitor--no-start --noscripts
dh_systemd_start -pmonitor
When building this package, I get the following error from the rules file:
dpkg-buildpackage -rfakeroot -us -uc -ui
dpkg-buildpackage: warning: using a gain-root-command while being root
dpkg-buildpackage: info: source package vm-perf-mon
dpkg-buildpackage: info: source version 2018.07.24.211328
dpkg-buildpackage: info: source distribution RELEASED
dpkg-buildpackage: info: source changed by root <root@034f0c4becfc>
dpkg-source --before-build debbuild
dpkg-buildpackage: info: host architecture amd64
fakeroot debian/rules clean
make:
: No such file or directory
make: *** No rule to make target '
'. Stop.
dpkg-buildpackage: error: fakeroot debian/rules clean subprocess returned exit status 2
debuild: fatal error at line 1152:
dpkg-buildpackage -rfakeroot -us -uc -ui failed
................................................................................ Issues:
- It claims that there is no rule to make a target, but the actual target name is blank.
- The rules file has no targets, except the default
%as a catch-all, and the over-ridendh_installinittarget. As far as I know,%is supposed to catch all undefined targets, and take care of it1.
Since the make target is blank, I'm not even sure where to start. I was wondering if anyone has either faced this before, or has any idea what this is or why this is happening.
I did read this, but in the OPs case there, it specified a target that had no rule.