[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Building binary package, howto enable init.d/systemd start



Hi,

> i am trying to build a binary debian package consisting of a python
> script, shell scripts and a config file as daemon with either init.d or
> systemd start.
> 
> The init.d script gets installed also the systemd file, but both are not
> enabled.

[...]

> In debian/rules is:
> 
> #!/usr/bin/make -f
> 
> DH_VERBOSE=1
> 
> %:
> 	dh $@
> clean:
> 	@# Do nothing
> 
> build:
> 	@# Do nothing
> 
> binary:

[...]

I suggest you use override_dh_auto_install instead or better use
debian/install (man dh_install) for what you do in this target.

> I have the strange feeling the entire postinstall stuff is missing.
> Is there a significant typo somewhere so obvious I am to stupid to see?

I think that overriding the binary target breaks debhelper.
 
[...]

> If there is a distribution like Mint Tessa for example, how does the
> system decide which startmethod to choose, if init.d and systemd are
> enabled successfully? I see a mix of init.d and systemd there regading
> starting stuff.

Your package will support both and the magic will happen at package
install phase. I think dh_installinit and dh_installsystemd generate
the postinst scripts that make this happen.

Cheers,

Alex


Reply to: