aboutsummaryrefslogtreecommitdiff
path: root/sysutils/ipfs-go
diff options
context:
space:
mode:
authorWilliam Grzybowski <wg@FreeBSD.org>2015-11-05 13:56:20 +0000
committerWilliam Grzybowski <wg@FreeBSD.org>2015-11-05 13:56:20 +0000
commitab209a5176477b273397eae496732ffc7f0a0b45 (patch)
tree95b27b3f045f7a4f5baf28057e7bf89e786c3d09 /sysutils/ipfs-go
parentbb20fe38f99dcd0c981e015b1f70d5091f556c08 (diff)
downloadports-ab209a5176477b273397eae496732ffc7f0a0b45.tar.gz
ports-ab209a5176477b273397eae496732ffc7f0a0b45.zip
sysutils/ipfs-go: fix build for i386
PR: 203991 Submitted by: amdmi3
Notes
Notes: svn path=/head/; revision=400853
Diffstat (limited to 'sysutils/ipfs-go')
-rw-r--r--sysutils/ipfs-go/Makefile11
-rw-r--r--sysutils/ipfs-go/files/extra-patch-32bit11
2 files changed, 18 insertions, 4 deletions
diff --git a/sysutils/ipfs-go/Makefile b/sysutils/ipfs-go/Makefile
index 81d23b5013a4..446ac2017687 100644
--- a/sysutils/ipfs-go/Makefile
+++ b/sysutils/ipfs-go/Makefile
@@ -16,9 +16,6 @@ USE_GITHUB= yes
GH_ACCOUNT= ipfs
GH_PROJECT= go-ipfs
-ONLY_FOR_ARCHS= amd64
-ONLY_FOR_ARCHS_REASON= Does not build on i386 due to a dependency
-
MAKE_ENV+= GOPATH=${WRKSRC}
PLIST_FILES= bin/${PORTNAME}
@@ -27,6 +24,12 @@ USE_RC_SUBR= ${PORTNAME}
STRIP= # stripping can break go binaries
+.include <bsd.port.pre.mk>
+
+.if ${ARCH} == i386
+EXTRA_PATCHES+= ${FILESDIR}/extra-patch-32bit
+.endif
+
# Prepare for possible extra modules in future
post-extract:
@${MKDIR} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}
@@ -41,4 +44,4 @@ do-build:
do-install:
${INSTALL_PROGRAM} ${WRKSRC}/src/github.com/${GH_ACCOUNT}/${GH_PROJECT}/cmd/ipfs/ipfs ${STAGEDIR}${PREFIX}/bin/${PORTNAME}
-.include <bsd.port.mk>
+.include <bsd.port.post.mk>
diff --git a/sysutils/ipfs-go/files/extra-patch-32bit b/sysutils/ipfs-go/files/extra-patch-32bit
new file mode 100644
index 000000000000..44d0e647b6c8
--- /dev/null
+++ b/sysutils/ipfs-go/files/extra-patch-32bit
@@ -0,0 +1,11 @@
+--- src/github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-reuseport/poll/poll_bsd.go.orig 2015-08-02 14:00:34 UTC
++++ src/github.com/ipfs/go-ipfs/Godeps/_workspace/src/github.com/jbenet/go-reuseport/poll/poll_bsd.go
+@@ -21,7 +21,7 @@ func New(fd int) (p *Poller, err error)
+ }
+
+ p.event = syscall.Kevent_t{
+- Ident: uint64(fd),
++ Ident: uint32(fd),
+ Filter: syscall.EVFILT_WRITE,
+ Flags: syscall.EV_ADD | syscall.EV_ENABLE | syscall.EV_ONESHOT,
+ Fflags: 0,