Tiny Core Linux

Tiny Core Extensions => TCE Talk => Topic started by: nitram on June 24, 2015, 09:04:19 PM

Title: tcz ownership and permission questions...
Post by: nitram on June 24, 2015, 09:04:19 PM
Have an amalgamation of information and can't remember exactly where i read this (wiki, forum, Core book). When preparing .tcz extensions, is the following ownership and permission information still accurate? For example, one source indicated binary should be root:root with 755 permission, another root:staff with 775 permission?

- binary should be root:staff with 775 permission
- shared object lib files (end in .so or .so*) are also treated as executable (root:staff, 775 permission)
- static object lib files (end in .a or .la) are classified as normal files (644 permission)
- all files root:root, 644 for files, 755 for executables, 755 for directories
- permissions of sym links will show as 777 which is normal

Also when i go though my system's /optional/*.tcz extensions, there are several oddball permssions. All extensions are tc:staff owned and most are 664. Here are some of the oddball permissions below. My system is otherwise working great, just wondering if there is a reason or explanation for these differences?
- aterm.tcz 575 and also tagged executable
- freetype.tcz 575 tagged executable
- glib2.tcz 620
- libX11.tcz 575 tagged executable
- libdrm.tcz 620
Title: Re: tcz ownership and permission questions...
Post by: bmarkus on June 25, 2015, 12:36:56 AM
Which version, which architecture are you referring?
Title: Re: tcz ownership and permission questions...
Post by: nitram on June 25, 2015, 12:58:01 AM
Sorry.
TC 6.3 x86
Title: Re: tcz ownership and permission questions...
Post by: curaga on June 25, 2015, 04:23:00 AM
There is no rule for binaries and libraries, usually what "make install" does is sufficient (root:root and suitable permissions).
Title: Re: tcz ownership and permission questions...
Post by: Juanito on June 25, 2015, 04:25:00 AM
I checked on the server - there were a few extensions mistakenly marked as executable (now corrected), but none of the ones you mentioned.

The ownership was correct on all of the extensions in the repo, so the error must be local.
Title: Re: tcz ownership and permission questions...
Post by: Misalf on June 25, 2015, 06:49:25 AM
Never had any problems with 'executable' extensions. Also, if core is installed on a DOS/Windows partition, everything on that file system is executable.

When compiling from source and creating extensions, I use:
Code: [Select]
sudo make DESTDIR=/tmp/extension-name install
which should create correct file permissions.

Quote
- all files root:root, 644 for files, 755 for executables, 755 for directories
I'm also not sure about root:root for executables. Might not be true/necessary for every possible file.
For example, my personal Firefox extension is currently tc:staff but root:staff did work as well.
Title: Re: tcz ownership and permission questions...
Post by: nitram on June 25, 2015, 11:09:12 PM
Thanks for all replies. My actual /optional/*.tcz extensions are all tc:staff, so no problem. Have no explanation why the permissions would be different. Always use the distro. ibiblio. org/ tinycorelinux/ repository and haven't purposely changed any permissions within /optional.

Regardless, thanks Juanito for checking the repo and removing the unnecessary executable tags. As a relative beginner, think i wil just stick with 'sudo make DESTDIR=/tmp/extension-name install' and leave it at that, although agree not every binary needs or probably should even be root:root.
Title: Re: tcz ownership and permission questions...
Post by: bmarkus on June 26, 2015, 01:40:36 AM
Always use the distro. ibiblio. org/ tinycorelinux/ repository...

In the specific case it is irrelevant, but better to use the main repo, repo.tinycorelinux.net instead of ibiblio which is a mirror.
Title: Re: tcz ownership and permission questions...
Post by: nitram on June 26, 2015, 03:34:05 AM
Thanks - changed repository to repo.tinycorelinux.

Think i figured out most of my permission issues - newbie hacked TC install :)

Folder permissions for /optional and /ondemand for a persistent install have been changed to 775 and all /optional/*.tcz extension permissions have been corrected.

No biggie, but in the process of discovery i downloaded and investigated TinyCore (15MB) and CorePlus (72MB). All of these .iso extensions in cde/optional appear correct (444 permissions) except the CorePlus gamin.tcz extension (555 plus an executable bit).

Thanks again everyone.
Title: Re: tcz ownership and permission questions...
Post by: Juanito on June 26, 2015, 06:39:41 AM
The gamin extension was one of those corrected - it will be fixed next time the ISO is built