Skip site navigation (1)Skip section navigation (2)
Date:      Fri, 26 Jun 2020 11:15:18 +0000 (UTC)
From:      =?UTF-8?Q?Fernando_Apestegu=c3=ada?= <fernape@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r540491 - in head/net/pichi: . files
Message-ID:  <202006261115.05QBFI6U062818@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: fernape
Date: Fri Jun 26 11:15:18 2020
New Revision: 540491
URL: https://svnweb.freebsd.org/changeset/ports/540491

Log:
  net/pichi: Fix build on 13.0-CURRENT
  
  The default c++ compiler on FreeBSD 13.0 CURRENT is Clang10, which has more
  strict type checking than the one on FreeBSD 12. So, adding some patch files to
  fix it.
  
  PR:	246854
  Submitted by:	pichi@elude.in (maintainer)

Added:
  head/net/pichi/files/patch-include_pichi_config.hpp.in   (contents, props changed)
  head/net/pichi/files/patch-server_main.cpp   (contents, props changed)
  head/net/pichi/files/patch-test_endpoint.cpp   (contents, props changed)
  head/net/pichi/files/patch-test_method.cpp   (contents, props changed)
  head/net/pichi/files/patch-test_utils.hpp   (contents, props changed)
Modified:
  head/net/pichi/Makefile

Modified: head/net/pichi/Makefile
==============================================================================
--- head/net/pichi/Makefile	Fri Jun 26 11:14:12 2020	(r540490)
+++ head/net/pichi/Makefile	Fri Jun 26 11:15:18 2020	(r540491)
@@ -21,17 +21,17 @@ USE_RC_SUBR=	pichi
 PLIST_SUB=	DISTVERSION=${DISTVERSION}
 
 CMAKE_BUILD_TYPE=	MinSizeRel
-CMAKE_ARGS=	-DVERSION=${DISTVERSION}
-CMAKE_ON=	BUILD_SERVER BUILD_TEST
-INSTALL_TARGET=	install/strip
-TEST_TARGET=	test
+CMAKE_ARGS=		-DVERSION=${DISTVERSION}
+CMAKE_ON=		BUILD_SERVER BUILD_TEST
+INSTALL_TARGET=		install/strip
+TEST_TARGET=		test
 
 OPTIONS_DEFINE=		DEVEL STATIC TLS
 OPTIONS_DEFAULT=	TLS
 OPTIONS_SUB=		yes
 
-TLS_DESC=	Enable TLS support ( requiring OpenSSL )
-TLS_CMAKE_BOOL=	ENABLE_TLS
+TLS_DESC=		Enable TLS support ( requiring OpenSSL )
+TLS_CMAKE_BOOL=		ENABLE_TLS
 
 STATIC_DESC=		Static linking
 STATIC_CMAKE_BOOL=	STATIC_LINK

Added: head/net/pichi/files/patch-include_pichi_config.hpp.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/net/pichi/files/patch-include_pichi_config.hpp.in	Fri Jun 26 11:15:18 2020	(r540491)
@@ -0,0 +1,18 @@
+--- include/pichi/config.hpp.in.orig	1970-01-01 00:00:00 UTC
++++ include/pichi/config.hpp.in
+@@ -42,6 +42,15 @@
+ #pragma warning(pop)
+ #endif // DISABLE_C4702_FOR_BEAST_FIELDS && _MSC_VER
+ 
++#ifdef __clang__
++#if !__has_feature(c_atomic)
++#pragma clang diagnostic push
++#pragma clang diagnostic ignored "-Wc11-extensions"
++#include <boost/smart_ptr/detail/sp_counted_base_clang.hpp>
++#pragma clang diagnostic pop
++#endif // !__has_feature(c_atomic)
++#endif // __clang__
++
+ #cmakedefine CMAKE_INSTALL_PREFIX "@CMAKE_INSTALL_PREFIX@"
+ 
+ #ifdef CMAKE_INSTALL_PREFIX

Added: head/net/pichi/files/patch-server_main.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/net/pichi/files/patch-server_main.cpp	Fri Jun 26 11:15:18 2020	(r540491)
@@ -0,0 +1,15 @@
+--- server/main.cpp.orig	1970-01-01 00:00:00 UTC
++++ server/main.cpp
+@@ -1,10 +1,11 @@
++#include <pichi/config.hpp>
++// Include config.hpp first
+ #include <boost/filesystem/operations.hpp>
+ #include <boost/filesystem/path.hpp>
+ #include <boost/program_options.hpp>
+ #include <fstream>
+ #include <iostream>
+ #include <memory>
+-#include <pichi/config.hpp>
+ #include <stdio.h>
+ #ifdef HAS_UNISTD_H
+ #include <errno.h>

Added: head/net/pichi/files/patch-test_endpoint.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/net/pichi/files/patch-test_endpoint.cpp	Fri Jun 26 11:15:18 2020	(r540491)
@@ -0,0 +1,12 @@
+--- test/endpoint.cpp.orig	1970-01-01 00:00:00 UTC
++++ test/endpoint.cpp
+@@ -132,7 +132,8 @@ BOOST_AUTO_TEST_CASE(serialize_Domain)
+ #ifndef HAS_CLASS_TEMPLATE_ARGUMENT_DEDUCTION
+       <uint8_t, 13>
+ #endif // HAS_CLASS_TEMPLATE_ARGUMENT_DEDUCTION
+-      {0x03, 0x09, 'l', 'o', 'c', 'a', 'l', 'h', 'o', 's', 't', 0x01, 0xbb};
++      {0x03_u8, 0x09_u8, 0x6c_u8, 0x6f_u8, 0x63_u8, 0x61_u8, 0x6c_u8,
++       0x68_u8, 0x6f_u8, 0x73_u8, 0x74_u8, 0x01_u8, 0xbb_u8};
+ 
+   auto fact = array<uint8_t, 13>{};
+   auto len = serializeEndpoint(makeEndpoint(host, port), fact);

Added: head/net/pichi/files/patch-test_method.cpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/net/pichi/files/patch-test_method.cpp	Fri Jun 26 11:15:18 2020	(r540491)
@@ -0,0 +1,9 @@
+--- test/method.cpp.orig	1970-01-01 00:00:00 UTC
++++ test/method.cpp
+@@ -1,5 +1,6 @@
+ #define BOOST_TEST_MODULE pichi method test
+ 
++#include "utils.hpp"
+ #include <boost/test/unit_test.hpp>
+ #include <pichi/common.hpp>
+ #include <pichi/crypto/method.hpp>

Added: head/net/pichi/files/patch-test_utils.hpp
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/net/pichi/files/patch-test_utils.hpp	Fri Jun 26 11:15:18 2020	(r540491)
@@ -0,0 +1,11 @@
+--- test/utils.hpp.orig	1970-01-01 00:00:00 UTC
++++ test/utils.hpp
+@@ -1,6 +1,8 @@
+ #ifndef PICHI_TEST_UTILS_HPP
+ #define PICHI_TEST_UTILS_HPP
+ 
++#include <pichi/config.hpp>
++// Include config.hpp first
+ #include <boost/asio/error.hpp>
+ #include <boost/beast/http/error.hpp>
+ #include <pichi/api/vos.hpp>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202006261115.05QBFI6U062818>