MESSAGE
DATE | 2015-11-19 |
FROM | prmarino1@gmail.com
|
SUBJECT | Re: [Hangout-NYLXS] permissions in Debian packages?
|
By the way thank you very much Chris for trying to help, and giving me a definitive answer it's very much appreciated and even though it wasn't the answer I hoped for at the very least I know I'm doing it the right and or acceptable way.
Original Message
From: prmarino1-at-gmail.com
Sent: Thursday, November 19, 2015 21:25
To: NYLXS Discussions List
Subject: Re: [Hangout-NYLXS] permissions in Debian packages?
Chris
Yea I've seen that method too. its still messy because it assumes you are compiling as root or have unlimited sudo on chown and or chmod permission.
It strikes me as very odd that they didn't adopt something similar to the files section of an RPM spec file by now, because I see a massive potential for package permissions/ownership clashes between packages without it.
Then again since RPM switched from open source to GPL along time ago I find it odd Debian didn't adopt it, but as us Perl programmers (differentiated from Perl scripters by the fact that we understand how references work and why they exist) put it there are many ways to do It.
I will say this it is a lot simpler when you get down to it than RPMS or ebuilds (Gentoo/Portage), but simplicity for the sake of simplicity isn't always your friend. :)
On Thu, Nov 19, 2015 at 6:05 PM, Chris Knadle wrote:
> Paul Robert Marino:
>> Ive been creating a few debian packages for my job and Ive noticed
>> something alarming.
>> is setting the file permissions prior to packaging and or using a post
>> install script the only way to set permissions and ownership on files
>> in a debian package?
>> this strikes me as very strange to say the least, is there a better way?
>
> Another way file permissions can be set during the build process is in the
> debian/rules file like this:
>
> -------------------------------------------------------
> %:
> dh $-at-
>
> override_dh_installinit:
> install -m 0755 $(CURDIR)/scripts/start.init $(CURDIR)/debian/thing.init
> dh_installinit
> -------------------------------------------------------
>
> So in this case if what's being packaged is a daemon called 'thing', the
> above will copy and rename the "start.init" init script during the build to
> debian/thing.init with permissions -rwxr-xr-x whereby dh_installinit will
> pick it up and install it to the binary package.
>
> Likewise you could call a script within the debian/rules file to change
> permissions on source files before the build. Unfortunately permissions
> isn't something that can be altered with a quilt patch.
>
> -- Chris
>
> --
> Chris Knadle
> Chris.Knadle-at-coredump.us
> _______________________________________________
> hangout mailing list
> hangout-at-nylxs.com
> http://www.nylxs.com/
_______________________________________________
hangout mailing list
hangout-at-nylxs.com
http://www.nylxs.com/
|
|