Skip to content

configure.ac, src/Makefile.am: Follow GNU coding standards regarding directory variables #1231

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

Draft
wants to merge 2 commits into
base: master
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 0 additions & 4 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -16,10 +16,6 @@ AC_SUBST([LIBSUBID_ABI_MINOR], [libsubid_abi_minor])
AC_SUBST([LIBSUBID_ABI_MICRO], [libsubid_abi_micro])
AC_SUBST([LIBSUBID_ABI], [libsubid_abi])

dnl Some hacks...
test "$prefix" = "NONE" && prefix="/usr"
test "$prefix" = "/usr" && exec_prefix=""

AC_USE_SYSTEM_EXTENSIONS

AC_ENABLE_STATIC
Expand Down
8 changes: 4 additions & 4 deletions src/Makefile.am
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@
EXTRA_DIST = \
.indent.pro

ubindir = ${prefix}/bin
usbindir = ${prefix}/sbin
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

With the current state of MR, the same exec_prefix will be used for ubindir && bindir

Do we keepubindir and usbindir in such case?
Or they are intentionally separate in Makefile.am so one can use make variables to have different values for ubindir and bindir e.g.

make install ubindir=/tmp/bin usbindir=/tmp/sbin

Otherwise LGTM and +1 for removing hacks :-)

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I want to remove them, but in a separate PR. I'd say even in a separate release, just to make sure we don't break anything at some point.

ubindir = $(exec_prefix)/bin
usbindir = $(exec_prefix)/sbin
suidperms = 4755
sgidperms = 2755

AM_CPPFLAGS = \
-I${top_srcdir}/lib \
-I$(top_srcdir)/lib \
-I$(top_srcdir) \
-DLOCALEDIR=\"$(datadir)/locale\" \
$(ECONF_CPPFLAGS)
Expand All @@ -24,7 +24,7 @@ AM_CFLAGS = $(LIBBSD_CFLAGS)
#
# also /lib/libshadow.so.x.xx (if any) could be moved to /usr/lib
# and installation would be much simpler (just two directories,
# $prefix/bin and $prefix/sbin, no install-data hacks...)
# $exec_prefix/bin and $exec_prefix/sbin, no install-data hacks...)

bin_PROGRAMS = login
sbin_PROGRAMS = nologin
Expand Down
Loading