-
Notifications
You must be signed in to change notification settings - Fork 4
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
Make install prefix #2
Comments
This is the patch I had to apply to compile the package in a buildroot environment --- a/Makefile.in 2018-07-25 19:02:11.000000000 +0200
+++ b/Makefile.in 2021-01-05 15:51:37.129518976 +0100
@@ -4,6 +4,7 @@
VERSION=1.29
+CC = @CC@
CFLAGS = @CFLAGS@ -Wall
prefix = @prefix@
man1dir=@mandir@/man1
@@ -42,13 +43,13 @@
$(CC) $(CFLAGS) -c mat.c
install: all
- $(INSTALL) -g bin -m 755 -o root adjtimex $(bindir)/adjtimex
- $(INSTALL) -d -g root -m 755 -o root $(mandir)
- -$(INSTALL) -g root -m 644 -o root $(srcdir)/adjtimex.8 \
- $(mandir)/adjtimex.$(manext)
+ $(INSTALL) -m 755 adjtimex $(DESTDIR)$(bindir)/adjtimex
+ $(INSTALL) -d -m 755 $(DESTDIR)$(mandir)
+ -$(INSTALL) -m 644 $(srcdir)/adjtimex.8 \
+ $(DESTDIR)$(mandir)/adjtimex.$(manext)
uninstall:
- rm -f $(bindir)/adjtimex $(mandir)/adjtimex.$(manext)
+ rm -f $(DESTDIR)$(bindir)/adjtimex $(DESTDIR)$(mandir)/adjtimex.$(manext)
clean:
rm -f core *.o |
Thanks for your report! I'm wondering whether you checked the patches under debian folder, especially those listed below:
So the first part of your patch to amend "CC" was already there. FYI. This git repo is for debian packaging, not for adjtimex upstream. |
Hi!
The install path for the adjtimex binary is hardcoded to /sbin in the Makefile which breaks compatibility with any build system that doesn't use fakeroot for installation (for example buildroot or openwrt).
I worked around this by patching the Makefile.in to honor the exec-prefix as it was in earlier versions.
In addition honoring the variable DESTDIR when running make install would be nice as this is how most buildsystems that come with autotool helpers try to set the install directory (which should be prepended before the set prefix or exec_prefix).
This would give the most flexibility
- Jakob
The text was updated successfully, but these errors were encountered: