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

suport for exec_prefix and libexecdir #364

Closed
tp-m opened this issue Jan 24, 2016 · 6 comments
Closed

suport for exec_prefix and libexecdir #364

tp-m opened this issue Jan 24, 2016 · 6 comments

Comments

@tp-m
Copy link
Member

tp-m commented Jan 24, 2016

I noticed meson does not have out of the box support for libexecdir yet.

Or, more generally speaking, there's also no distinction between --prefix and --exec-prefix which autotools seems to make these days, e.g. ./configure --help shows:

Installation directories:
  --prefix=PREFIX         install architecture-independent files in PREFIX
                          [/usr/local]
  --exec-prefix=EPREFIX   install architecture-dependent files in EPREFIX
                          [PREFIX]

It seems to default to this for libexecdir, but distros will likely want to override that:

libdir = ${exec_prefix}/lib
libexecdir = ${exec_prefix}/libexec

exec_prefix will likely be the same as prefix, and default to the same, but the distinction seems useful.

@jpakkane
Copy link
Member

What are the use cases for these? When would you install to exec-prefix/libexecdir/whatever instead of regular prefix/bin or somesuch? Is there a case when a project would want to install to both at the same time?

@tp-m
Copy link
Member Author

tp-m commented Jan 25, 2016

Not sure how much light I can shed on practical use cases here, I can only point out that these exist in the autotools-world and that in my experience distro packagers make use of all of these (perhaps due to packaging guidelines): https://www.gnu.org/prep/standards/html_node/Directory-Variables.html

@jpakkane
Copy link
Member

Hmmm. That document does not really tell why they are needed, only that they are. And it is written assuming (understandably) Autotools' late evaluation semantics.

I'm all for supporting this, but I'm hesitant to add functionality without understanding the reasoning behind it. That usually leads to code that seems to work but does the wrong thing. Getting comments from someone who has dealt with this issue would be necessary to get this functionality to come out right.

@ignatenkobrain
Copy link
Member

libexecdir sometimes is used..

For tracker, telepathy, NM, ibus, gvfs and many other stuff. What is exec_prefix I have no idea.

@nirbheek
Copy link
Member

libexecdir is used for 'helper' executables that are not supposed to be run by the user and should not be in PATH. They are usually helpers that are executed by libraries or via dbus activation. You will see lots of things in /usr/libexec on Fedora. GStreamer uses this too.

In theory, exec_prefix vs prefix allows you to share the architecture-independent prefix between several machines or to create an image that can run on multiple architectures without duplicating everything. In practice, I've never seen anyone use this.

@tp-m
Copy link
Member Author

tp-m commented Mar 18, 2016

libexecdir support is there now, let's skip the exec_prefix part until someone actually has a use for it.

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

4 participants