[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [gnunet] branch master updated: contrib: Move scripts conte
From: |
gnunet |
Subject: |
[GNUnet-SVN] [gnunet] branch master updated: contrib: Move scripts content to scripts/Makefile Actually build the contrib perl script. Add an m4 script for perl. |
Date: |
Tue, 19 Mar 2019 18:08:38 +0100 |
This is an automated email from the git hooks/post-receive script.
ng0 pushed a commit to branch master
in repository gnunet.
The following commit(s) were added to refs/heads/master by this push:
new c5d729bcf contrib: Move scripts content to scripts/Makefile Actually
build the contrib perl script. Add an m4 script for perl.
c5d729bcf is described below
commit c5d729bcff1471a357e75f10f5a782154983fd8f
Author: ng0 <address@hidden>
AuthorDate: Tue Mar 19 16:42:33 2019 +0000
contrib: Move scripts content to scripts/Makefile
Actually build the contrib perl script.
Add an m4 script for perl.
---
configure.ac | 7 +
contrib/Makefile.am | 37 +----
contrib/scripts/Makefile.am | 43 +++++
contrib/scripts/documentation/gnunet-doc.scm | 182 ---------------------
contrib/scripts/gnunet-logread/Makefile.am | 22 +++
...ead-ipc-sdedit => gnunet-logread-ipc-sdedit.in} | 0
.../{gnunet-logread => gnunet-logread.in} | 0
m4/perl.m4 | 48 ++++++
8 files changed, 121 insertions(+), 218 deletions(-)
diff --git a/configure.ac b/configure.ac
index d69683ff8..a8c80eb7d 100644
--- a/configure.ac
+++ b/configure.ac
@@ -214,6 +214,11 @@ AM_PATH_PYTHON([3.7],, [:])
AC_SUBST([PYTHON])
AM_CONDITIONAL([HAVE_PYTHON], [test "$PYTHON" != :])
+# perl
+AC_PATH_PROG( PERL, perl, ,
+ $PATH:/usr/local/bin/perl:/usr/bin/:/usr/local/bin )
+AC_SUBST([PERL])
+
# iptables is a soft requirement to run tests
AC_PATH_TARGET_TOOL(VAR_IPTABLES_BINARY, iptables, false)
@@ -1722,6 +1727,8 @@ AC_DEFINE_UNQUOTED(VCS_VERSION, [$vcs_version], [VCS
revision/hash or tarball ve
AC_CONFIG_FILES([
Makefile
contrib/Makefile
+contrib/scripts/Makefile
+contrib/scripts/gnunet-logread/Makefile
doc/Makefile
doc/man/Makefile
doc/doxygen/Makefile
diff --git a/contrib/Makefile.am b/contrib/Makefile.am
index 49aa36dfd..ff1d1fbbb 100644
--- a/contrib/Makefile.am
+++ b/contrib/Makefile.am
@@ -5,13 +5,7 @@ tap32dir = $(pkgdatadir)/openvpn-tap32/tapw32/
tap64dir = $(pkgdatadir)/openvpn-tap32/tapw64/
-noinst_SCRIPTS = \
- scripts/terminate.py \
- scripts/pydiffer.py \
- scripts/removetrailingwhitespace.py \
- scripts/gnunet_pyexpect.py \
- scripts/gnunet_janitor.py \
- scripts/gnunet-chk.py
+SUBDIRS = scripts
dist_pkgdata_DATA = \
gns/gns-bcd.html \
@@ -46,14 +40,6 @@ EXTRA_DIST = \
conf/gnunet/no_autostart_above_core.conf \
conf/nss/nssswitch.conf \
conf/wireshark/wireshark.lua \
- scripts/coverage.sh \
- scripts/terminate.py.in \
- scripts/gnunet_pyexpect.py.in \
- scripts/gnunet_janitor.py.in \
- scripts/gnunet-chk.py.in \
- scripts/gnunet-bugreport \
- scripts/removetrailingwhitespace.py.in \
- scripts/pydiffer.py.in \
packages/nix/default.nix \
packages/nix/gnunet-dev.nix \
3rdparty/Windows/openvpn-tap32/tapw32/tap0901.sys \
@@ -67,27 +53,6 @@ EXTRA_DIST = \
3rdparty/Windows/openvpn-tap32/tap32-source-2.1.zip \
$(INITD_FILES)
-CLEANFILES = \
- $(noinst_SCRIPTS)
-
-do_subst = $(SED) -e 's,address@hidden@],$(PYTHON),g'
-
-# Use SUFFIX Extension rules, they are more portable for every
-# implementation of 'make'.
-# You'll also run into the "'%' is a GNU make extension warning"
-# if you use this:
-#
-#%.py: %.py.in Makefile
-# $(do_subst) < $< > $@
-# chmod +x $@
-#
-# instead of this:
-SUFFIXES = .py.in .py
-
-.py.in.py:
- $(do_subst) < $< > $@
- chmod +x $@
-
check_PROGRAMS = \
test_gnunet_prefix
diff --git a/contrib/scripts/Makefile.am b/contrib/scripts/Makefile.am
new file mode 100644
index 000000000..a9eadf337
--- /dev/null
+++ b/contrib/scripts/Makefile.am
@@ -0,0 +1,43 @@
+# This Makefile.am is in the public domain
+AM_CPPFLAGS = -I$(top_srcdir)/src/include -I$(top_builddir)/src/include
+
+SUBDIRS = gnunet-logread
+
+noinst_SCRIPTS = \
+ terminate.py \
+ pydiffer.py \
+ removetrailingwhitespace.py \
+ gnunet_pyexpect.py \
+ gnunet_janitor.py \
+ gnunet-chk.py
+
+EXTRA_DIST = \
+ coverage.sh \
+ terminate.py.in \
+ gnunet_pyexpect.py.in \
+ gnunet_janitor.py.in \
+ gnunet-chk.py.in \
+ gnunet-bugreport \
+ removetrailingwhitespace.py.in \
+ pydiffer.py.in
+
+CLEANFILES = \
+ $(noinst_SCRIPTS)
+
+do_subst = $(SED) -e 's,address@hidden@],$(PYTHON),g'
+
+# Use SUFFIX Extension rules, they are more portable for every
+# implementation of 'make'.
+# You'll also run into the "'%' is a GNU make extension warning"
+# if you use this:
+#
+#%.py: %.py.in Makefile
+# $(do_subst) < $< > $@
+# chmod +x $@
+#
+# instead of this:
+SUFFIXES = .py.in .py
+
+.py.in.py:
+ $(do_subst) < $< > $@
+ chmod +x $@
diff --git a/contrib/scripts/documentation/gnunet-doc.scm
b/contrib/scripts/documentation/gnunet-doc.scm
deleted file mode 100644
index 077efacad..000000000
--- a/contrib/scripts/documentation/gnunet-doc.scm
+++ /dev/null
@@ -1,182 +0,0 @@
-;;; This file is part of GNUnet.
-;;; Copyright (C) 2016, 2017 GNUnet e.V.
-;;;
-;;; GNUnet is free software: you can redistribute it and/or modify it
-;;; under the terms of the GNU Affero General Public License as published
-;;; by the Free Software Foundation, either version 3 of the License, or
-;;; (at your option) any later version.
-;;;
-;;; GNUnet is distributed in the hope that it will be useful, but
-;;; WITHOUT ANY WARRANTY; without even the implied warranty of
-;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-;;; Affero General Public License for more details.
-;;;
-;;; You should have received a copy of the GNU Affero General Public License
-;;; along with this program. If not, see <http://www.gnu.org/licenses/>.
-;;;
-
-(use-modules
- (ice-9 popen)
- (ice-9 match)
- (ice-9 rdelim)
- (guix packages)
- (guix build-system gnu)
- (guix gexp)
- ((guix build utils) #:select (with-directory-excursion))
- (guix git-download)
- (guix utils) ; current-source-directory
- (gnu packages)
- (gnu packages aidc)
- (gnu packages autotools)
- (gnu packages backup)
- (gnu packages base)
- (gnu packages compression)
- (gnu packages curl)
- (gnu packages databases)
- (gnu packages file)
- (gnu packages gettext)
- (gnu packages glib)
- (gnu packages gnome)
- (gnu packages gnunet)
- (gnu packages gnupg)
- (gnu packages gnuzilla)
- (gnu packages groff)
- (gnu packages gstreamer)
- (gnu packages gtk)
- (gnu packages guile)
- (gnu packages graphviz)
- (gnu packages image)
- (gnu packages image-viewers)
- (gnu packages libidn)
- (gnu packages libunistring)
- (gnu packages linux)
- (gnu packages maths)
- (gnu packages multiprecision)
- (gnu packages perl)
- (gnu packages pkg-config)
- (gnu packages pulseaudio)
- (gnu packages python)
- (gnu packages tex)
- (gnu packages texinfo)
- (gnu packages tex)
- (gnu packages tls)
- (gnu packages video)
- (gnu packages web)
- (gnu packages xiph)
- ;;(gnunet packages texlive) ;GNUnet module including texlive-2012 WIP
- ((guix licenses) #:prefix license:))
-
-;;(define %source-dir (string-append (current-source-directory)
-;; "/../../../"))
-(define %source-dir (dirname (current-filename)))
-
-(define gnunet-doc
- (let* ((revision "2")
- (select? (delay (or (git-predicate
- (string-append (current-source-directory)
- "/../../../"))
- source-file?))))
- (package
- (name "gnunet-doc")
- (version (string-append "0.10.1-" revision "." "dev"))
- (source
- (local-file ;;"../../.."
- ;;%source-dir
- ;;(string-append (getcwd) "/../../../")
- (string-append (getcwd)) ;drrty hack and this assumes one static
position FIXME!
- #:recursive? #t))
- ;;#:select? (git-predicate %source-dir)))
- ;;#:select? (force select?)))
- (build-system gnu-build-system)
- (inputs
- `(("glpk" ,glpk)
- ("gnurl" ,gnurl)
- ("gstreamer" ,gstreamer)
- ("gst-plugins-base" ,gst-plugins-base)
- ("gnutls/dane" ,gnutls/dane)
- ("libextractor" ,libextractor)
- ("libgcrypt" ,libgcrypt)
- ("libidn" ,libidn)
- ("libmicrohttpd" ,libmicrohttpd)
- ("libltdl" ,libltdl)
- ("libunistring" ,libunistring)
- ("openssl" ,openssl)
- ("opus" ,opus)
- ("pulseaudio" ,pulseaudio)
- ("sqlite" ,sqlite)
- ("postgresql" ,postgresql)
- ("mysql" ,mariadb)
- ("zlib" ,zlib)
- ("perl" ,perl)
- ("python-2" ,python-2) ; tests and gnunet-qr
- ("jansson" ,jansson)
- ("nss" ,nss)
- ("glib" ,glib "bin")
- ("gmp" ,gmp)
- ("bluez" ,bluez) ; for optional bluetooth feature
- ("glib" ,glib)
- ;;("texlive-minimal" ,texlive-minimal) ; optional.
- ("texlive" ,texlive) ;TODO: Stabilize Texlive-2012 package
- ("libogg" ,libogg)))
- (native-inputs
- `(("pkg-config" ,pkg-config)
- ("autoconf" ,autoconf)
- ("automake" ,automake)
- ("gnu-gettext" ,gnu-gettext)
- ("graphviz" ,graphviz) ; dot
- ("texinfo-5" ,texinfo-5) ; Debian stable
- ("which" ,which)
- ("libtool" ,libtool)))
- (arguments
- `(#:configure-flags
- (list "--enable-documentation")
- #:tests? #f ;Don't run tests
- #:phases
- (modify-phases %standard-phases
- (add-after 'unpack 'autoconf
- (lambda _
- (substitute* "bootstrap"
- (("contrib/pogen.sh") "sh contrib/pogen.sh"))
- (for-each (lambda (f) (chmod f #o755))
- (find-files "po" ""))
- (zero? (system* "sh" "bootstrap"))))
- (add-after 'build 'run-gendocs
- (lambda _
- (chdir "doc/documentation")
- ;;(zero? (system* "make" "dev-build"))))
- (zero? (system* "sh" "run-gendocs.sh"))))
- ;; (zero? (system* "make" "pdf"))
- ;; (zero? (system* "make" "html"))
- ;; (zero? (system* "make" "info"))))
- ;;(zero? (system* "make" "doc-all-give-me-the-noise"))))
- (replace 'install
- (lambda _
- (zero? (system* "make" "doc-gendoc-install")))))))
- ;;(lambda* (#:key outputs #:allow-other-keys)
- ;; (let* ((out (assoc-ref outputs "out"))
- ;; (doc (string-append out "/share/doc/gnunet")))
- ;; (mkdir-p doc)
- ;; (copy-recursively "images"
- ;; (string-append doc
- ;; "/images"))
- ;; (mkdir-p (string-append doc "/gnunet"))
- ;; (install-file "gnunet.pdf" doc)
- ;; (install-file "gnunet.info" doc)
- ;; (install-file "gnunet.log" doc) ;TODO: Move to 'dev' output?
- ;; (copy-recursively "gnunet"
- ;; (string-append doc
- ;; "/gnunet"))
- ;; (install-file "gnunet-c-tutorial.pdf" doc)
- ;; (install-file "gnunet-c-tutorial.info" doc)
- ;; (install-file "gnunet-c-tutorial.log" doc) ;TODO: Move to 'dev'
output?
- ;; (copy-recursively "gnunet-c-tutorial"
- ;; (string-append doc
- ;; "/gnunet-c-tutorial")))
- ;; #t)))))
- (synopsis "Documentation of GNUnet")
- (description
- "GNUnet documentation build")
- (license (list license:fdl1.3+ license:gpl3+))
- (home-page "https://gnunet.org/"))))
-
-gnunet-doc
diff --git a/contrib/scripts/gnunet-logread/Makefile.am
b/contrib/scripts/gnunet-logread/Makefile.am
new file mode 100644
index 000000000..82c99494c
--- /dev/null
+++ b/contrib/scripts/gnunet-logread/Makefile.am
@@ -0,0 +1,22 @@
+# This Makefile.am is in the public domain
+AM_CPPFLAGS = -I$(top_srcdir)/src/include -I$(top_builddir)/src/include
+
+do_subst = $(SED) -e 's,address@hidden@],$(PERL),g'
+
+SUFFIXES = .in
+
+gnunet-logread: gnunet-logread.in Makefile
+ $(do_subst) < $(srcdir)/gnunet-logread.in > gnunet-logread
+ chmod +x gnunet-logread
+
+gnunet-logread-ipc-sdedit: gnunet-logread-ipc-sdedit.in Makefile
+ $(do_subst) < $(srcdir)/gnunet-logread-ipc-sdedit.in >
gnunet-logread-ipc-sdedit
+ chmod +x gnunet-logread-ipc-sdedit
+
+CLEANFILES= \
+ gnunet-logread \
+ gnunet-logread-ipc-sdedit
+
+noinst_SCRIPTS = \
+ $(CLEANFILES) \
+ gnunet-logread-ipc
diff --git a/contrib/scripts/gnunet-logread/gnunet-logread-ipc-sdedit
b/contrib/scripts/gnunet-logread/gnunet-logread-ipc-sdedit.in
similarity index 100%
rename from contrib/scripts/gnunet-logread/gnunet-logread-ipc-sdedit
rename to contrib/scripts/gnunet-logread/gnunet-logread-ipc-sdedit.in
diff --git a/contrib/scripts/gnunet-logread/gnunet-logread
b/contrib/scripts/gnunet-logread/gnunet-logread.in
similarity index 100%
rename from contrib/scripts/gnunet-logread/gnunet-logread
rename to contrib/scripts/gnunet-logread/gnunet-logread.in
diff --git a/m4/perl.m4 b/m4/perl.m4
new file mode 100644
index 000000000..6f855c7a6
--- /dev/null
+++ b/m4/perl.m4
@@ -0,0 +1,48 @@
+# serial 9
+
+dnl From Jim Meyering.
+dnl Find a new-enough version of Perl.
+
+# Copyright (C) 1998-2001, 2003-2004, 2007, 2009-2018 Free Software Foundation,
+# Inc.
+#
+# This file is free software; the Free Software Foundation
+# gives unlimited permission to copy and/or distribute it,
+# with or without modifications, as long as this notice is preserved.
+
+# GNUnet e.V. comment of origin: gnulib
+
+AC_DEFUN([gl_PERL],
+[
+ dnl FIXME: don't hard-code 5.005
+ AC_MSG_CHECKING([for perl5.005 or newer])
+ if test "${PERL+set}" = set; then
+ # 'PERL' is set in the user's environment.
+ candidate_perl_names="$PERL"
+ perl_specified=yes
+ else
+ candidate_perl_names='perl perl5'
+ perl_specified=no
+ fi
+
+ found=no
+ AC_SUBST([PERL])
+ PERL="$am_missing_run perl"
+ for perl in $candidate_perl_names; do
+ # Run test in a subshell; some versions of sh will print an error if
+ # an executable is not found, even if stderr is redirected.
+ if ( $perl -e 'require 5.005; use File::Compare' ) > /dev/null 2>&1; then
+ PERL=$perl
+ found=yes
+ break
+ fi
+ done
+
+ AC_MSG_RESULT([$found])
+ test $found = no && AC_MSG_WARN([
+WARNING: You don't seem to have perl5.005 or newer installed, or you lack
+ a usable version of the Perl File::Compare module. As a result,
+ you may be unable to run a few tests or to regenerate certain
+ files if you modify the sources from which they are derived.
+] )
+])
--
To stop receiving notification emails like this one, please contact
address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] [gnunet] branch master updated: contrib: Move scripts content to scripts/Makefile Actually build the contrib perl script. Add an m4 script for perl.,
gnunet <=