- Allow make test

PR:		215346
Submitted by:	jbeich
This commit is contained in:
Sunpoet Po-Chuan Hsieh 2016-12-17 12:57:13 +00:00
parent b7d763c8ad
commit eb52e2d45d
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/head/; revision=428734
4 changed files with 31 additions and 3 deletions

View file

@ -12,17 +12,25 @@ COMMENT= Data interchange format library
LICENSE= BSD3CLAUSE
LICENSE_FILE= ${WRKSRC}/LICENSE
TEST_DEPENDS= googlemock>=0:devel/googlemock \
googletest>=0:devel/googletest
BROKEN_sparc64= fails to compile: no atomic ops available
CFLAGS+= -DGOOGLE_PROTOBUF_NO_RTTI
GNU_CONFIGURE= yes
INSTALL_TARGET= install-strip
TEST_ARGS= ${MAKE_ARGS} ${_MAKE_JOBS}
TEST_TARGET= check
USE_CSTD= c99 # for audio/clementine-player support
USE_LDCONFIG= yes
USES= autoreconf gmake libtool pathfix pkgconfig
USES= autoreconf gmake libtool localbase pathfix pkgconfig
GH_ACCOUNT= google
USE_GITHUB= yes
post-patch:
@${REINPLACE_CMD} -e 's|^check-local:|disabled-&|' ${WRKSRC}/Makefile.am
@${REINPLACE_CMD} -Ee '/gtest|mock/ s|[^ ]*lib(.*)\.la|-l\1|' ${WRKSRC}/src/Makefile.am
.include <bsd.port.mk>

View file

@ -1,6 +1,6 @@
--- src/google/protobuf/stubs/atomicops.h.orig 2015-05-06 14:28:24 UTC
--- src/google/protobuf/stubs/atomicops.h.orig 2016-09-24 02:12:45 UTC
+++ src/google/protobuf/stubs/atomicops.h
@@ -202,6 +202,8 @@ GOOGLE_PROTOBUF_ATOMICOPS_ERROR
@@ -202,6 +202,8 @@ Atomic64 Release_Load(volatile const Ato
#elif defined(__GNUC__)
#if defined(GOOGLE_PROTOBUF_ARCH_IA32) || defined(GOOGLE_PROTOBUF_ARCH_X64)
#include <google/protobuf/stubs/atomicops_internals_x86_gcc.h>

View file

@ -0,0 +1,10 @@
--- src/google/protobuf/testing/zcgunzip.cc.orig 2016-09-24 02:12:45 UTC
+++ src/google/protobuf/testing/zcgunzip.cc
@@ -42,6 +42,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
+#include <unistd.h>
#ifdef _WIN32
#ifndef STDIN_FILENO

View file

@ -0,0 +1,10 @@
--- src/google/protobuf/testing/zcgzip.cc.orig 2016-09-24 02:12:45 UTC
+++ src/google/protobuf/testing/zcgzip.cc
@@ -41,6 +41,7 @@
#include <stdio.h>
#include <stdlib.h>
#include <fcntl.h>
+#include <unistd.h>
#ifdef _WIN32
#ifndef STDIN_FILENO