Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Binary files should not be in /usr/share/ #46

Closed
dlech opened this issue Oct 3, 2016 · 7 comments
Closed

Binary files should not be in /usr/share/ #46

dlech opened this issue Oct 3, 2016 · 7 comments

Comments

@dlech
Copy link
Contributor

dlech commented Oct 3, 2016

What version of electron-installer-debian are you using?
0.3.1
What version of node and npm are you using?
v6.1.0
3.8.6
What operating system are you using?
debian jessie

What did you do? Please include the configuration you are using for electron-installer-debian.
Built a debian package from an electron package. No special configuration.

electron-installer-debian --src etcher-release/Etcher-linux-x64/ --dest etcher-release/debian/ --arch amd64

What did you expect to happen?

In the package that was created, /usr/share/ should only contain architecture interdependent files.

What actually happened?

/usr/share/ contains architecture dependent binary files.


Installing the electron package to /usr/lib/<package> instead of /usr/share/<package> would be more appropriate.

@dlech
Copy link
Contributor Author

dlech commented Oct 3, 2016

References:

@unindented
Copy link
Collaborator

Umm, I was following what atom does: https://github.com/atom/atom/blob/f58d70a8fdaf50294d2d4447a6efc612f4beb9db/script/lib/create-debian-package.js#L34

Do you think they are wrong?

@dlech
Copy link
Contributor Author

dlech commented Oct 3, 2016

It is certainly wrong according to FSH and debian policy. I don't think it actually causes any technical problems though. It's just that if I was looking for binaries, /usr/share/ would be the last place I would look.

@unindented
Copy link
Collaborator

vscode seems to install to /usr/share too: https://github.com/Microsoft/vscode/blob/555b4f0bf9a0bebe95c28d0e66a0336df48eab5c/build/gulpfile.vscode.linux.js#L39-L40

Maybe we are missing something in the guidelines?

@dlech
Copy link
Contributor Author

dlech commented Oct 3, 2016

I think atom and vscode are missing (or choosing to ignore) the guidelines. 😃

Debian policy is quite clear. From https://www.debian.org/doc/debian-policy/ch-opersys.html#s9.1:

The FHS requirement that architecture-independent application-specific static files be located in /usr/share is relaxed to a suggestion. In particular, a subdirectory of /usr/lib may be used by a package (or a collection of packages) to hold a mixture of architecture-independent and architecture-dependent files. However, when a directory is entirely composed of architecture-independent files, it should be located in /usr/share.

@unindented
Copy link
Collaborator

Yup, sounds pretty clear. Any dangerous side effects you can think of? If not, feel free to create a PR and I'll merge it.

@dlech
Copy link
Contributor Author

dlech commented Oct 3, 2016

Nothing dangerous. The only potential problem I see is that if another package (not created with electron-installed-debian) has files at /usr/lib/<package>, then packages that are created with electron-installer-debian will fail to install because of conflicting files.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants