[PATCH] Allow building as non-root user

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



If building as non-root user for testing purposes, the build fails:
...
libtool: install: /usr/bin/install -c wall /opt/gnome2/bin/wall
test -z "/opt/gnome2/sbin" || /bin/mkdir -p "/opt/gnome2/sbin"
make  install-exec-hook
make[3]: Entering directory `/home/oxyde/gnome2/util-linux-ng/login-utils'
chgrp: changing group of `/opt/gnome2/bin/wall': Operation not permitted
make[3]: *** [install-exec-hook] Error 1
make[2]: *** [install-exec-am] Error 2
make[1]: *** [install-am] Error 2
make: *** [install-recursive] Error 1
...

Allow building as non-root user.
Signed-off-by: Craig Keogh <cskeogh@xxxxxxxxxxx>
---
diff --git a/login-utils/Makefile.am b/login-utils/Makefile.am
index 177c0b6..9185bc5 100644
--- a/login-utils/Makefile.am
+++ b/login-utils/Makefile.am
@@ -108,7 +108,7 @@ dist_man_MANS += wall.1
 if USE_TTY_GROUP
 if MAKEINSTALL_DO_CHOWN
 install-exec-hook::
-	chgrp tty $(DESTDIR)$(usrbin_execdir)/wall
+	-chgrp tty $(DESTDIR)$(usrbin_execdir)/wall
 	chmod g+s $(DESTDIR)$(usrbin_execdir)/wall
 endif
 endif
diff --git a/misc-utils/Makefile.am b/misc-utils/Makefile.am
index a4f2f44..356e804 100644
--- a/misc-utils/Makefile.am
+++ b/misc-utils/Makefile.am
@@ -102,7 +102,7 @@ write_LDFLAGS = $(SUID_LDFLAGS) $(AM_LDFLAGS)
 if USE_TTY_GROUP
 if MAKEINSTALL_DO_CHOWN
 install-exec-hook::
-	chgrp tty $(DESTDIR)$(usrbin_execdir)/write
+	-chgrp tty $(DESTDIR)$(usrbin_execdir)/write
 	chmod g+s $(DESTDIR)$(usrbin_execdir)/write
 endif
 endif


--
To unsubscribe from this list: send the line "unsubscribe util-linux-ng" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]

  Powered by Linux