aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2011-11-02 15:37:42 +0000
committerChristian Grothoff <christian@grothoff.org>2011-11-02 15:37:42 +0000
commitd825f9ccd99b0b74278c8773ee6fba2d7974a1a9 (patch)
tree27d57109b43fc3f090be810a30901307e106cfda
parent9c3523a5786f8e961edf791eb9c2c6cc2149a60c (diff)
downloadgnunet-d825f9ccd99b0b74278c8773ee6fba2d7974a1a9.tar.gz
gnunet-d825f9ccd99b0b74278c8773ee6fba2d7974a1a9.zip
fixing #1820
-rw-r--r--README7
-rw-r--r--configure.ac21
-rw-r--r--src/nat/Makefile.am4
-rw-r--r--src/transport/Makefile.am4
-rw-r--r--src/vpn/Makefile.am8
5 files changed, 36 insertions, 8 deletions
diff --git a/README b/README
index ce7393ba8..978ae2916 100644
--- a/README
+++ b/README
@@ -84,6 +84,13 @@ configuration file slightly so that data can be stored in
84"/var/lib/gnunet"; you may also want to use "/etc/gnunet.conf" for the 84"/var/lib/gnunet"; you may also want to use "/etc/gnunet.conf" for the
85location of the configuration file in this case. 85location of the configuration file in this case.
86 86
87You can avoid running 'make install' as root if you run configure
88with the "--with-sudo=yes" option and have extensive sudo rights
89(can run chmod +s and chown via sudo). If you run 'make install'
90as a normal user without sudo rights (or the configure option),
91certain binaries that require additional priviledges will not be
92installed properly (and NAT traversal, WLAN and VPN will not work).
93
87Note that additional, per-user configuration files 94Note that additional, per-user configuration files
88(~/.gnunet/gnunet.conf) need to be created by each user (for example, 95(~/.gnunet/gnunet.conf) need to be created by each user (for example,
89by running gnunet-setup). Note that gnunet-setup is a separate 96by running gnunet-setup). Note that gnunet-setup is a separate
diff --git a/configure.ac b/configure.ac
index c12b2f414..148c827bc 100644
--- a/configure.ac
+++ b/configure.ac
@@ -676,6 +676,27 @@ AC_SUBST(DLLDIR)
676AC_SUBST(EXT_LIB_PATH) 676AC_SUBST(EXT_LIB_PATH)
677 677
678 678
679# test for sudo
680AC_MSG_CHECKING(for sudo)
681AC_ARG_WITH(sudo,
682 [ --with-sudo=PATH path to sudo binary (or just yes)],
683 [AC_MSG_RESULT("$with_sudo")
684 case $with_sudo in
685 no)
686 SUDO_BINARY=
687 ;;
688 yes)
689 SUDO_BINARY=sudo
690 ;;
691 *)
692 SUDO_BINARY=$with_sudo
693 ;;
694 esac
695 ],
696 [AC_MSG_RESULT([no])])
697AC_SUBST(SUDO_BINARY)
698
699
679# should 'make check' run tests? 700# should 'make check' run tests?
680AC_MSG_CHECKING(whether to run tests) 701AC_MSG_CHECKING(whether to run tests)
681AC_ARG_ENABLE([testruns], 702AC_ARG_ENABLE([testruns],
diff --git a/src/nat/Makefile.am b/src/nat/Makefile.am
index 97758df62..5adab1ae5 100644
--- a/src/nat/Makefile.am
+++ b/src/nat/Makefile.am
@@ -18,8 +18,8 @@ NATBIN = gnunet-helper-nat-server gnunet-helper-nat-client
18NATSERVER = gnunet-helper-nat-server.c 18NATSERVER = gnunet-helper-nat-server.c
19NATCLIENT = gnunet-helper-nat-client.c 19NATCLIENT = gnunet-helper-nat-client.c
20install-exec-hook: 20install-exec-hook:
21 chown root:root $(bindir)/gnunet-helper-nat-server $(bindir)/gnunet-helper-nat-client $(nattest) || true 21 $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-nat-server $(bindir)/gnunet-helper-nat-client $(nattest) || true
22 chmod u+s $(bindir)/gnunet-helper-nat-server $(bindir)/gnunet-helper-nat-client $(nattest) || true 22 $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-nat-server $(bindir)/gnunet-helper-nat-client $(nattest) || true
23else 23else
24install-exec-hook: 24install-exec-hook:
25endif 25endif
diff --git a/src/transport/Makefile.am b/src/transport/Makefile.am
index 2b86a05ba..06bea95ba 100644
--- a/src/transport/Makefile.am
+++ b/src/transport/Makefile.am
@@ -40,8 +40,8 @@ endif
40 40
41if LINUX 41if LINUX
42install-exec-hook: 42install-exec-hook:
43 chown root:root $(bindir)/gnunet-transport-wlan-helper || true 43 $(SUDO_BINARY) chown root:root $(bindir)/gnunet-transport-wlan-helper || true
44 chmod u+s $(bindir)/gnunet-transport-wlan-helper || true 44 $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-transport-wlan-helper || true
45else 45else
46install-exec-hook: 46install-exec-hook:
47endif 47endif
diff --git a/src/vpn/Makefile.am b/src/vpn/Makefile.am
index 0c61aa904..d0abc6522 100644
--- a/src/vpn/Makefile.am
+++ b/src/vpn/Makefile.am
@@ -12,10 +12,10 @@ if LINUX
12VPNBIN = gnunet-helper-vpn 12VPNBIN = gnunet-helper-vpn
13HIJACKBIN = gnunet-helper-hijack-dns 13HIJACKBIN = gnunet-helper-hijack-dns
14install-exec-hook: 14install-exec-hook:
15 chown root:root $(bindir)/gnunet-helper-vpn || true 15 $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-vpn || true
16 chmod u+s $(bindir)/gnunet-helper-vpn || true 16 $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-vpn || true
17 chown root:root $(bindir)/gnunet-helper-hijack-dns || true 17 $(SUDO_BINARY) chown root:root $(bindir)/gnunet-helper-hijack-dns || true
18 chmod u+s $(bindir)/gnunet-helper-hijack-dns || true 18 $(SUDO_BINARY) chmod u+s $(bindir)/gnunet-helper-hijack-dns || true
19else 19else
20install-exec-hook: 20install-exec-hook:
21endif 21endif