gnunet: update to version 0.16.1
authorDaniel Golle <daniel@makrotopia.org>
Sun, 13 Mar 2022 01:29:49 +0000 (01:29 +0000)
committerDaniel Golle <daniel@makrotopia.org>
Sun, 13 Mar 2022 13:14:44 +0000 (13:14 +0000)
 * OPUS and Pulse can be configured nicely by default now, no longer
   need a local patch for that
 * mysql version checks fail when cross-compiling, add patch to remove
   them and always assume MySQL >8.0.
 * Package new services, communicators, ...

This is a new major release. It breaks protocol compatibility with the
0.15.x versions. Please be aware that Git master is thus henceforth
(and has been for a while) INCOMPATIBLE with the 0.15.x GNUnet network,
and interactions between old and new peers will result in issues.
0.15.x peers will be able to communicate with Git master or 0.16.x
peers, but some services - in particular GNS - will not be compatible.

Signed-off-by: Daniel Golle <daniel@makrotopia.org>
net/gnunet/Makefile
net/gnunet/patches/010-endian.patch
net/gnunet/patches/100-fix-opus-and-pulse-library-detection.patch [deleted file]
net/gnunet/patches/100-remove-mysql-version-check.patch [new file with mode: 0644]

index 6510ea76b844e5fa5118fb775c9f61d78877c491..0b53e5e1798b4ad511b6c9c0012cab619912697e 100644 (file)
@@ -2,11 +2,11 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=gnunet
 
-PKG_VERSION:=0.15.3
+PKG_VERSION:=0.16.1
 PKG_RELEASE:=$(AUTORELEASE)
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
 PKG_SOURCE_URL:=@GNU/gnunet
-PKG_HASH:=d62669a8f41e078eaa220ce77a32f4f3f801e3099357ae8c705498fe73884ec5
+PKG_HASH:=df8026dd0b1c285ebc57e820e6b29e87c3d0f210bb0899f6b5317261f8e01c5c
 
 PKG_LICENSE:=AGPL-3.0
 PKG_LICENSE_FILES:=COPYING
@@ -23,25 +23,26 @@ PKG_BUILD_DEPENDS:=sqlite3
 include $(INCLUDE_DIR)/package.mk
 include $(INCLUDE_DIR)/nls.mk
 
-# always pass --with-sqlite as configure fails when trying --without-sqlite
+# always pass --with-sqlite3 as configure fails when trying --without-sqlite3
 CONFIGURE_ARGS+= \
        --with-libiconv-prefix="$(ICONV_PREFIX)" \
        --with-libintl-prefix="$(INTL_PREFIX)" \
        --with-ltdl \
        $(if $(CONFIG_PACKAGE_$(PKG_NAME)-mysql),--with-mysql="$(STAGING_DIR)/usr",--without-mysql) \
        $(if $(CONFIG_PACKAGE_$(PKG_NAME)-pgsql),--with-postgresql="$(STAGING_DIR)/usr/bin/pg_config",--without-postgresql) \
-       --with-sqlite="$(STAGING_DIR)/usr" \
-       --enable-testing \
+       --with-sqlite3="$(STAGING_DIR)/usr" \
        --disable-testruns \
        --disable-documentation \
        --enable-experimental \
        --with-extractor=$(STAGING_DIR)/usr \
        --with-gnutls=$(STAGING_DIR)/usr \
-       $(if $(CONFIG_PACKAGE_$(PKG_NAME)-transport-bluetooth),--with-libbluetooth="$(STAGING_DIR)/usr",--without-libbluetooth) \
+       $(if $(CONFIG_PACKAGE_$(PKG_NAME)-transport-bluetooth),--with-bluetooth="$(STAGING_DIR)/usr",--without-bluetooth) \
        --with-libgnurl=$(STAGING_DIR)/usr \
-       --with-libogg=$(STAGING_DIR)/usr \
-       --with-libopus=$(STAGING_DIR)/usr \
-       --with-libpulse=$(STAGING_DIR)/usr \
+       --with-ogg=$(STAGING_DIR)/usr \
+       --with-opus=$(STAGING_DIR)/usr \
+       --with-pabc=$(STAGING_DIR)/usr \
+       --with-png=$(STAGING_DIR)/usr \
+       --with-pulse=$(STAGING_DIR)/usr \
        --with-libunistring-prefix=$(STAGING_DIR)/usr \
        --with-microhttpd=$(STAGING_DIR)/usr
 
@@ -151,28 +152,28 @@ define Package/gnunet/install
            core datacache dht dns fragmentation friends hello \
            identity natauto natnew nse nt peerinfo peerstore regexblock regex revocation \
            scalarproduct set seti setu statistics transport transportapplication \
-           transportcore transportmonitor util; do \
+           transportcommunicator transportcore transportmonitor util; do \
                $(CP) $(PKG_INSTALL_DIR)/usr/lib/libgnunet$$$$lib.so* $(1)/usr/lib/ ; \
        done )
 
-       ( for plug in ats_proportional block_dht block_regex block_revocation transport_unix; do \
+       ( for plug in ats_proportional block_dht block_regex block_revocation dhtu_gnunet dhtu_ip transport_unix; do \
                $(CP) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libgnunet_plugin_$$$$plug*.so $(1)/usr/lib/gnunet ; \
        done )
 
-       ( for lex in daemon-topology helper-nat-client \
+       ( for lex in communicator-unix daemon-topology helper-nat-client \
            helper-nat-server service-arm service-ats service-ats-new service-cadet \
            service-core service-dht service-identity service-nat service-nat-auto \
            service-nse service-peerinfo service-peerstore service-regex \
            service-revocation service-scalarproduct-alice \
            service-scalarproduct-bob service-scalarproduct-ecc-alice \
            service-scalarproduct-ecc-bob service-set service-seti service-setu service-statistics \
-           service-transport timeout; do \
+           service-tng service-transport timeout; do \
                $(INSTALL_BIN) $(PKG_INSTALL_DIR)/usr/lib/gnunet/libexec/gnunet-$$$$lex $(1)/usr/lib/gnunet/libexec ; \
        done )
 
-       ( for conf in arm ats cadet core datacache dht identity \
+       ( for conf in arm ats cadet communicator-unix core datacache dht dhtu identity \
            nat nat-auto nse peerinfo peerstore regex revocation \
-           scalarproduct set seti setu statistics topology transport util; do \
+           scalarproduct set seti setu statistics tlds topology transport util; do \
                $(INSTALL_DATA) $(PKG_INSTALL_DIR)/usr/share/gnunet/config.d/$$$$conf.conf $(1)/usr/share/gnunet/config.d ; \
        done )
 
@@ -223,6 +224,9 @@ DEPENDS_hostlist:=+libmicrohttpd-ssl +gnunet-curl +ca-certificates
 LIBEXEC_hostlist:=daemon-hostlist
 CONF_hostlist:=hostlist
 
+LIBEXEC_communicator-udp:=communicator-udp
+LIBEXEC_communicator-tcp:=communicator-tcp
+
 DEPENDS_transport-bluetooth:=+bluez-libs
 PLUGIN_transport-bluetooth:=transport_bluetooth
 LIBEXEC_transport-bluetooth:=helper-transport-bluetooth
@@ -280,9 +284,10 @@ BIN_messenger:=messenger
 LIB_messenger:=messenger
 LIBEXEC_messenger:=service-messenger
 CONF_messenger:=messenger
+PLUGIN_messenger:=gnsrecord_messenger
 
 DEPENDS_reclaim:=+gnunet-gns +gnunet-sqlite +libpbc +libgabe +jansson
-BIN_reclaim:=reclaim
+BIN_reclaim:=did reclaim
 LIB_reclaim:=consensus abe reclaim reclaimattribute secretsharing
 LIBEXEC_reclaim:=service-consensus service-reclaim service-secretsharing
 CONF_reclaim:=consensus reclaim secretsharing
@@ -407,7 +412,7 @@ $(eval $(call PostInstFixSUIDPerms,gnunet-transport-wlan))
 $(eval $(call PostInstFixSUIDPerms,gnunet-vpn))
 
 $(eval $(call BuildPackage,gnunet))
-#$(eval $(call BuildComponent,abd,credential service components,))
+$(eval $(call BuildComponent,abd,credential service components,))
 $(eval $(call BuildComponent,auction,auction components,))
 $(eval $(call BuildComponent,conversation,conversation component,))
 $(eval $(call BuildComponent,curl,cURL wrapper component,))
@@ -438,6 +443,8 @@ $(eval $(call BuildComponent,dhtcache-sqlite,libsqlite3 dhtcache plugin,))
 $(eval $(call BuildComponent,fs-sqlite,libsqlite3 filesharing plugin,))
 $(eval $(call BuildComponent,gns-sqlite,libsqlite3 gns plugins,))
 $(eval $(call BuildComponent,peerstore-sqlite,libsqlite3 peerstore plugin,))
+$(eval $(call BuildComponent,communicator-tcp,tng transport TCP communicator,y))
+$(eval $(call BuildComponent,communicator-udp,tng transport UDP communicator,y))
 $(eval $(call BuildComponent,transport-bluetooth,bluetooth transport,))
 $(eval $(call BuildComponent,transport-http_client,HTTP/HTTPS client transport,y))
 $(eval $(call BuildComponent,transport-http_server,HTTP/HTTPS server transport,))
index 4a956f14b09ef3d899e574f81a781a4321cf9ca4..f07ab7eaf17673761c73ef29e12de076cc868e84 100644 (file)
@@ -1,14 +1,14 @@
 --- a/src/include/gnunet_common.h
 +++ b/src/include/gnunet_common.h
-@@ -142,7 +142,6 @@ enum GNUNET_GenericReturnValue
+@@ -150,7 +150,6 @@ enum GNUNET_GenericReturnValue
   * Endian operations
   */
  
 -#if __BYTE_ORDER == __LITTLE_ENDIAN
- #if defined(__linux__)
- #define BYTE_SWAP_16(x) __bswap_16 (x)
- #define BYTE_SWAP_32(x) __bswap_32 (x)
-@@ -162,6 +161,7 @@ enum GNUNET_GenericReturnValue
+ #ifdef HAVE_BYTESWAP_H
+ #define BYTE_SWAP_16(x) bswap_16 (x)
+ #define BYTE_SWAP_32(x) bswap_32 (x)
+@@ -170,6 +169,7 @@ enum GNUNET_GenericReturnValue
                                               56))
  #endif
  
diff --git a/net/gnunet/patches/100-fix-opus-and-pulse-library-detection.patch b/net/gnunet/patches/100-fix-opus-and-pulse-library-detection.patch
deleted file mode 100644 (file)
index 0e40bb4..0000000
+++ /dev/null
@@ -1,36 +0,0 @@
---- a/configure.ac
-+++ b/configure.ac
-@@ -851,10 +851,12 @@ AC_ARG_WITH(libpulse,
-             LDFLAGS="-L$with_libpulse/lib $LDFLAGS"
-             CPPFLAGS="-I$with_libpulse/include $CPPFLAGS"
-             AC_CHECK_HEADERS(pulse/simple.h,
--                             AC_CHECK_LIB([pulse],
--                                          [pa_stream_peek],
--                                          EXT_LIB_PATH="-L$with_libpulse/lib $EXT_LIB_PATH"
--                                          pulse=1))
-+                             AC_CHECK_DECL([pa_stream_peek],
-+                                       [pulse=1],
-+                                       [],
-+                                       [[
-+                                       #include <pulse/stream.h>
-+                                       ]]))
-         ])
-     ],
-     [AC_MSG_RESULT([--with-libpulse not specified])
-@@ -894,10 +896,12 @@ AC_ARG_WITH(libopus,
-         LDFLAGS="-L$with_libopus/lib $LDFLAGS"
-         CPPFLAGS="-I$with_libopus/include $CPPFLAGS"
-         AC_CHECK_HEADERS(opus/opus.h,
--                         AC_CHECK_LIB([opus],
--                                      [OPUS_SET_GAIN],
--                                      EXT_LIB_PATH="-L$with_libopus/lib $EXT_LIB_PATH"
--                                      opus=1))
-+                         AC_CHECK_DECL([OPUS_SET_GAIN],
-+                                       [opus=1],
-+                                       [],
-+                                       [[
-+                                       #include <opus/opus.h>
-+                                       ]]))
-       ])
-     ],
-     [AC_MSG_RESULT([--with-libopus not specified])
diff --git a/net/gnunet/patches/100-remove-mysql-version-check.patch b/net/gnunet/patches/100-remove-mysql-version-check.patch
new file mode 100644 (file)
index 0000000..26d233f
--- /dev/null
@@ -0,0 +1,38 @@
+--- a/configure.ac
++++ b/configure.ac
+@@ -978,33 +978,13 @@ AC_ARG_WITH([mysql],
+     AC_CHECK_LIB([mysqlclient], [mysql_init],
+       [AC_CHECK_HEADERS([mysql/mysql.h],
+          [MYSQL_LDFLAGS="-L$MYSQL_LIBDIR"
+-          mysql=true],
++          mysql=true
++          mysql8=true],
+          [mysql=false])],
+       [mysql=false])])
+ AC_SUBST(MYSQL_LDFLAGS)
+ AC_SUBST(MYSQL_CPPFLAGS)
+-# additional version checks for mysql
+-AS_IF([test "x$mysql" = "xtrue"],
+-  [AC_MSG_CHECKING([for mysql version])
+-   AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
+-     [[include <mysql/mysql_version.h>]],
+-     [[#if (MYSQL_VERSION_ID < 40100)
+-#error required at least version 4.1
+-#endif]])],
+-     [mysql=true],
+-     [mysql=false])
+-   AS_IF([test "x$mysql" = "xfalse"],
+-     [AC_MSG_RESULT([< 4.1])
+-      AC_MSG_RESULT([mysql version >= 4.1 required. Will not use MySQL])])
+-   AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
+-     [[#include <mysql/mysql_version.h>]],
+-     [[#if (MYSQL_VERSION_ID < 80000)
+-#error needs at least version 8.0
+-#endif]])],
+-     [mysql8=true],
+-     [mysql8=false])])
+-
+ AS_IF([test "x$mysql" = "xtrue"],
+   [AS_IF([test "x$mysql8" = "xfalse"],
+      [AC_MSG_RESULT([between 4.1 and 8.0])],