aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjadawin <jadawin@FreeBSD.org>2013-11-27 21:16:47 +0800
committerjadawin <jadawin@FreeBSD.org>2013-11-27 21:16:47 +0800
commitc63ae3bbbaee2877058b7e6699b4e490070760d7 (patch)
tree25c01236b5e992f6180b12437e7c1177ab42220a
parentc78a4c5a32fba8d594f34a278f7144e93cf4cbf0 (diff)
downloadfreebsd-ports-gnome-c63ae3bbbaee2877058b7e6699b4e490070760d7.tar.gz
freebsd-ports-gnome-c63ae3bbbaee2877058b7e6699b4e490070760d7.tar.zst
freebsd-ports-gnome-c63ae3bbbaee2877058b7e6699b4e490070760d7.zip
- Fix build
- Support STAGEDIR PR: ports/184238 Submitted by: KATO Tsuguru <tkato432@yahoo.com>
-rw-r--r--biology/lagan/Makefile20
-rw-r--r--biology/lagan/files/patch-src__glocal__rightinfluence.cpp32
2 files changed, 42 insertions, 10 deletions
diff --git a/biology/lagan/Makefile b/biology/lagan/Makefile
index 94992ee37f08..6005caaa84be 100644
--- a/biology/lagan/Makefile
+++ b/biology/lagan/Makefile
@@ -39,7 +39,6 @@ SCRIPTUTILS= cmerge2.pl draft.pl mextract.pl mf2bin.pl mpretty.pl \
READMES= README.FIRST README.chaos README.lagan README.mlagan \
README.tools README.shuffle
-NO_STAGE= yes
post-patch:
@${FIND} ${WRKSRC} -name "Makefile" | ${XARGS} ${REINPLACE_CMD} -e \
'/^CC/s|^|#| ; \
@@ -47,26 +46,27 @@ post-patch:
s|$$(CC) -o|$$(CC) $$(CFLAGS) -o| ; \
s|$$(CPP) -o|$$(CXX) $$(CXXFLAGS) -o| ; \
s|$$(CLINKER) $$(OPTFLAGS)|$$(CXX) $$(LDFLAGS)|'
+ @${FIND} ${WRKSRC}/src -name "*.c" | ${XARGS} ${REINPLACE_CMD} -e \
+ 's|^inline |static inline |'
do-install:
- @${MKDIR} ${LAGAN_DIR}
+ @${MKDIR} ${STAGEDIR}${LAGAN_DIR}
.for exe in ${EXECUTABLES}
- ${INSTALL_PROGRAM} ${WRKSRC}/${exe} ${LAGAN_DIR}
+ ${INSTALL_PROGRAM} ${WRKSRC}/${exe} ${STAGEDIR}${LAGAN_DIR}
.endfor
.for script in ${SCRIPTS}
- ${INSTALL_SCRIPT} ${WRKSRC}/${script} ${LAGAN_DIR}
+ ${INSTALL_SCRIPT} ${WRKSRC}/${script} ${STAGEDIR}${LAGAN_DIR}
.endfor
- @${MKDIR} ${LAGAN_DIR}/utils
+ @${MKDIR} ${STAGEDIR}${LAGAN_DIR}/utils
.for exeutil in ${EXEUTILS}
- ${INSTALL_PROGRAM} ${WRKSRC}/utils/${exeutil} ${LAGAN_DIR}/utils
+ ${INSTALL_PROGRAM} ${WRKSRC}/utils/${exeutil} ${STAGEDIR}${LAGAN_DIR}/utils
.endfor
.for scriptutil in ${SCRIPTUTILS}
- ${INSTALL_SCRIPT} ${WRKSRC}/utils/${scriptutil} ${LAGAN_DIR}/utils
+ ${INSTALL_SCRIPT} ${WRKSRC}/utils/${scriptutil} ${STAGEDIR}${LAGAN_DIR}/utils
.endfor
- @${MKDIR} ${LAGAN_DIR}/Readmes
+ @${MKDIR} ${STAGEDIR}${LAGAN_DIR}/Readmes
.for readme in ${READMES}
- ${INSTALL_DATA} ${WRKSRC}/Readmes/${readme} ${LAGAN_DIR}/Readmes
+ ${INSTALL_DATA} ${WRKSRC}/Readmes/${readme} ${STAGEDIR}${LAGAN_DIR}/Readmes
.endfor
- @${CAT} ${PKGMESSAGE}
.include <bsd.port.mk>
diff --git a/biology/lagan/files/patch-src__glocal__rightinfluence.cpp b/biology/lagan/files/patch-src__glocal__rightinfluence.cpp
new file mode 100644
index 000000000000..6ee5be408229
--- /dev/null
+++ b/biology/lagan/files/patch-src__glocal__rightinfluence.cpp
@@ -0,0 +1,32 @@
+--- src/glocal/rightinfluence.cpp.orig
++++ src/glocal/rightinfluence.cpp
+@@ -1,6 +1,6 @@
+ #include <rightinfluence.h>
+
+-Fragment origin, end;
++Fragment origin, my_end;
+
+ // Sets the first default owner of the whole region
+ void initRI(RI *RightInfluence, long long int scoreIndex) {
+@@ -18,17 +18,17 @@
+
+ // hack to aid winner selection
+ origin.score = -1;
+- end.score = -2;
+- origin.totalScore = end.totalScore = 0;
++ my_end.score = -2;
++ origin.totalScore = my_end.totalScore = 0;
+
+ // will win against anyone
+- end.seq1End = 0; end.seq2End = 0;
+- end.seq1Start = 0; end.seq2Start = 0;
++ my_end.seq1End = 0; my_end.seq2End = 0;
++ my_end.seq1Start = 0; my_end.seq2Start = 0;
+
+ origin.back = NULL;
+
+ RightInfluence->act[-INF] = &origin;
+- RightInfluence->act[+INF] = &end;
++ RightInfluence->act[+INF] = &my_end;
+ }
+