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

DESTDIR support in make install #35

Closed
kodo-pp opened this issue Jul 3, 2019 · 0 comments · Fixed by #42
Closed

DESTDIR support in make install #35

kodo-pp opened this issue Jul 3, 2019 · 0 comments · Fixed by #42

Comments

@kodo-pp
Copy link

kodo-pp commented Jul 3, 2019

Setting custom install location independent from $PREFIX should be implemented. For example, I want make DESTDIR=/tmp/pkg PREFIX=/usr install to install libraries and headers to /tmp/pkg/usr, but write libdir and includedir entries to pkg-config files based only on $PREFIX (like $PREFIX/lib and $PREFIX/include, but not $DESTDIR/$PREFIX/whatever).

The main reason for it is packaging. When you are creating a package you often need to install the program or library to a temporary directory, which then will be archived and will go to the package. Simply setting PREFIX doesn't help because it will make pkg-config entries to look like this (incorrect): /path/to/pkgdir/usr/include instead of this (correct): /usr/include. You can see it in detail in this terminal transcript: https://gist.github.com/kodo-pp/482bef5afbece8bdb3c01bac461b1e03

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

Successfully merging a pull request may close this issue.

1 participant