Bug 128057 - Update biology/avida to 2.8.1
Summary: Update biology/avida to 2.8.1
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Dmitry Marakasov
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2008-10-13 13:40 UTC by Christian Sturm
Modified: 2008-10-23 15:20 UTC (History)
0 users

See Also:


Attachments
file.txt (1.57 KB, text/plain)
2008-10-13 13:40 UTC, Christian Sturm
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description Christian Sturm 2008-10-13 13:40:05 UTC
I updated the unmaintained port biology/avida to recent stable version 2.8.1.
While building I get:

[ 57%] Building CXX object CMakeFiles/avidacore.dir/source/main/cTaskLib.o
/usr/ports/biology/avida/work/avida-src-2.8.1/source/main/cTaskLib.cc: In member function 'double cTaskLib::Task_Log2(cTaskContext&) const':
/usr/ports/biology/avida/work/avida-src-2.8.1/source/main/cTaskLib.cc:2507: error: 'log2' was not declared in this scope
*** Error code 1

A partial patch/diff is attached.

Fix: Patch attached with submission follows:
Comment 1 Dmitry Marakasov freebsd_committer freebsd_triage 2008-10-13 13:51:01 UTC
Responsible Changed
From-To: freebsd-ports-bugs->amdmi3

I'll take it.
Comment 2 Dmitry Marakasov 2008-10-13 13:54:58 UTC
> Synopsis: Update biology/avida to 2.8.1
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=128057
Hi, thanks for your submission!

Actually I have pending changes to this port - some cleanups and
cmake usage improvements (i.e. move to cmake.mk) - I think it's nice
opportunity to finish them up and commit along with the port update.

Also, are you interested in maintaining this port?

-- 
Dmitry Marakasov   .   55B5 0596 FF1E 8D84 5F56  9510 D35A 80DD F9D2 F77D
amdmi3@amdmi3.ru  ..:  jabber: amdmi3@jabber.ru    http://www.amdmi3.ru
Comment 3 Dmitry Marakasov 2008-10-13 18:28:32 UTC
> Synopsis: Update biology/avida to 2.8.1
> 
> http://www.freebsd.org/cgi/query-pr.cgi?pr=128057

Here's the update, could you please test it?

--- avida.patch begins here ---
Index: Makefile
===================================================================
RCS file: /home/amdmi3/projects/freebsd/FreeBSD.cvs/ports/biology/avida/Makefile,v
retrieving revision 1.23
diff -u -r1.23 Makefile
--- Makefile	3 Sep 2008 02:57:44 -0000	1.23
+++ Makefile	13 Oct 2008 17:02:58 -0000
@@ -6,47 +6,35 @@
 #
 
 PORTNAME=	avida
-PORTVERSION=	2.4.3
+PORTVERSION=	2.8.1
 CATEGORIES=	biology
-MASTER_SITES=	${MASTER_SITE_SOURCEFORGE}
-MASTER_SITE_SUBDIR=	${PORTNAME}
-DISTNAME=	${PORTNAME}-src-${PORTVERSION}
+MASTER_SITES=	SF
+DISTNAME=	${PORTNAME}-${PORTVERSION}-src
 
 MAINTAINER=	ports@FreeBSD.org
 COMMENT=	Avida is an auto-adaptive genetic system designed for ALife research
 
-BUILD_DEPENDS=	cmake:${PORTSDIR}/devel/cmake
+USE_CMAKE=	yes
+USE_GCC=	4.2+
 
-CMAKE_ARGS=	-DPROJECT_BINARY_DIR=${WRKSRC}/build/work \
-		-DAVD_CONSISTENCY_TEST_PRIMITIVE:BOOL=OFF \
-		-DAVD_GUI_NCURSES:BOOL=ON \
-		-DAVD_PRIMITIVE:BOOL=ON \
-		-DAVD_UNIT_TESTS:BOOL=OFF\
-		-DCMAKE_BUILD_TYPE:STRING=Release
-
-WRKSRC=		${WRKDIR}/${PORTNAME}
-
-do-build:
-	@(cd ${BUILD_WRKSRC}; \
-	${MKDIR} build build/work; \
-	cd build; \
-	cmake ${CMAKE_ARGS} ..; \
-	${MAKE})
-
-do-install:
-	@(cd ${BUILD_WRKSRC}; \
-	cd build; \
-	${MAKE} install)
+WRKSRC=		${WRKDIR}/${PORTNAME}-src-${PORTVERSION}
+
+PORTDOCS=	*
+
+.include <bsd.port.pre.mk>
+
+post-extract:
+	@${RM} -f ${WRKSRC}/documentation/.[D_]*
 
 post-install:
-	${MKDIR} ${PREFIX}/share/${PORTNAME}
-	(cd ${WRKSRC}/build/work/work; \
-	${INSTALL_PROGRAM} AvidaConsole ${PREFIX}/bin; \
-	${INSTALL_PROGRAM} task_event_gen ${PREFIX}/bin; \
-	${INSTALL_DATA} analyze.cfg environment.cfg events.cfg genesis genesis.4stack inst_set.4stack inst_set.default organism.default ${PREFIX}/share/${PORTNAME} )
+	${INSTALL_PROGRAM} ${WRKSRC}/work/avida ${PREFIX}/bin
+	${INSTALL_PROGRAM} ${WRKSRC}/work/avida-viewer ${PREFIX}/bin
+	${MKDIR} ${DATADIR}
+	${INSTALL_DATA} ${WRKSRC}/work/*.cfg ${WRKSRC}/work/*.org ${DATADIR}
 .if !defined(NOPORTDOCS)
 	${MKDIR} ${DOCSDIR}
-	(${CP} -RP ${WRKSRC}/documentation/ ${DOCSDIR})
+	cd ${WRKSRC}/documentation && ${COPYTREE_SHARE} . ${DOCSDIR}
 .endif
 
-.include <bsd.port.mk>
+
+.include <bsd.port.post.mk>
Index: distinfo
===================================================================
RCS file: /home/amdmi3/projects/freebsd/FreeBSD.cvs/ports/biology/avida/distinfo,v
retrieving revision 1.5
diff -u -r1.5 distinfo
--- distinfo	8 Jul 2006 03:36:36 -0000	1.5
+++ distinfo	13 Oct 2008 15:06:02 -0000
@@ -1,3 +1,3 @@
-MD5 (avida-src-2.4.3.tar.gz) = 44c3f1df0fe5d62a08cb0a64dc9c5ac2
-SHA256 (avida-src-2.4.3.tar.gz) = 4a883138d9da57c99defe521de96e7851f453e1a003c978a6dbb178c8a51ba11
-SIZE (avida-src-2.4.3.tar.gz) = 1725948
+MD5 (avida-2.8.1-src.tar.gz) = 99d9405921a23df1813e34c96106cd47
+SHA256 (avida-2.8.1-src.tar.gz) = 554a82081f550e49f795ecda34d6e19a91239e8dc500b6590f46d08839179ef7
+SIZE (avida-2.8.1-src.tar.gz) = 1609168
Index: pkg-plist
===================================================================
RCS file: /home/amdmi3/projects/freebsd/FreeBSD.cvs/ports/biology/avida/pkg-plist,v
retrieving revision 1.4
diff -u -r1.4 pkg-plist
--- pkg-plist	8 Jul 2006 03:36:36 -0000	1.4
+++ pkg-plist	13 Oct 2008 16:27:36 -0000
@@ -1,122 +1,15 @@
-bin/AvidaConsole
-bin/task_event_gen
+bin/avida
+bin/avida-viewer
 %%DATADIR%%/analyze.cfg
+%%DATADIR%%/avida.cfg
+%%DATADIR%%/default-classic.org
+%%DATADIR%%/default-sex-classic.org
+%%DATADIR%%/default-smt.org
+%%DATADIR%%/default-transsmt.org
 %%DATADIR%%/environment.cfg
 %%DATADIR%%/events.cfg
-%%DATADIR%%/genesis
-%%DATADIR%%/genesis.4stack
-%%DATADIR%%/inst_set.4stack
-%%DATADIR%%/inst_set.default
-%%DATADIR%%/organism.default
-%%PORTDOCS%%%%DOCSDIR%%/content/using/CMakeLists.txt
-%%PORTDOCS%%%%DOCSDIR%%/content/using/analyze_mode.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/analyze_samples.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_c++_intro.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_death_birth.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_environment.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_events.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_genesis.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_genome.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_init_file.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_instruction.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_life_cycle.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/code_task.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/cpu2.gif
-%%PORTDOCS%%%%DOCSDIR%%/content/using/cpu_tour.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/cvs.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/devel.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/environment.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/events.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/genesis.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/CMakeLists.txt
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/components.help
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Bitwise.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.CPU-cycle.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.CPU.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Complement-Template.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Genome.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Genotype.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Heads.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.IO.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Input-Output.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Instruction.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Logic.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Memory.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Mutation.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Nop-Head-Notation.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Nop-Register-Notation.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Organism.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Population.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Registers.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Stack.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Tasks.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.Template.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.add.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.dec.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.h-alloc.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.h-copy.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.h-divide.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.h-search.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.if-label.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.if-less.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.if-n-equ.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.inc.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.jmp-head.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.mov-head.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.nand.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.nop-instructions.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.pop.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.push.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.set-flow.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.shift-l.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.shift-r.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.sub.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.swap-stk.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/help.swap.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/inst.help
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/notations.help
-%%PORTDOCS%%%%DOCSDIR%%/content/using/glossary/todo.help
-%%PORTDOCS%%%%DOCSDIR%%/content/using/index.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/inst_set.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/level_map.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/print_data.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/screen.html
-%%PORTDOCS%%%%DOCSDIR%%/content/using/structure.html
-%%PORTDOCS%%%%DOCSDIR%%/forrest/README.txt
-%%PORTDOCS%%%%DOCSDIR%%/forrest/classes/CatalogManager.properties
-%%PORTDOCS%%%%DOCSDIR%%/forrest/skinconf.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/langcode.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/languages_en.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/languages_es.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_af.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_de.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_es.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_it.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_no.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_ru.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/menu_sk.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/tabs.xml
-%%PORTDOCS%%%%DOCSDIR%%/forrest/translations/tabs_es.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/admin/index.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/admin/third-party-osx.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/admin/third-party-win32.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/images/group-logo.gif
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/images/group.svg
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/images/icon.png
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/images/project-logo.gif
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/images/project.svg
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/index.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/site.xml
-%%PORTDOCS%%%%DOCSDIR%%/xdocs/tabs.xml
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/xdocs/images
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/xdocs/admin
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/xdocs
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/forrest/translations
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/forrest/classes
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/forrest
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/content/using/glossary
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/content/using
-%%PORTDOCS%%@dirrm %%DOCSDIR%%/content
-%%PORTDOCS%%@dirrm %%DOCSDIR%%
+%%DATADIR%%/instset-classic.cfg
+%%DATADIR%%/instset-sex-classic.cfg
+%%DATADIR%%/instset-smt.cfg
+%%DATADIR%%/instset-transsmt.cfg
 @dirrm %%DATADIR%%
Index: files/patch-source-main-cTaskLib.cc
===================================================================
RCS file: files/patch-source-main-cTaskLib.cc
diff -N files/patch-source-main-cTaskLib.cc
--- /dev/null	1 Jan 1970 00:00:00 -0000
+++ files/patch-source-main-cTaskLib.cc	13 Oct 2008 17:27:32 -0000
@@ -0,0 +1,12 @@
+--- source/main/cTaskLib.cc.orig	2007-09-05 23:53:07.000000000 +0400
++++ source/main/cTaskLib.cc	2008-10-13 19:32:10.000000000 +0400
+@@ -41,8 +41,8 @@
+ // Various workarounds for Visual Studio shortcomings
+ #if AVIDA_PLATFORM(WINDOWS)
+ # define llabs(x) _abs64(x)
+-# define log2(x) (log(x)/log(2.0))
+ #endif
++# define log2(x) (log(x)/log(2.0))
+ 
+ static const double dCastPrecision = 100000.0;
+ 
--- avida.patch ends here ---

-- 
Dmitry Marakasov   .   55B5 0596 FF1E 8D84 5F56  9510 D35A 80DD F9D2 F77D
amdmi3@amdmi3.ru  ..:  jabber: amdmi3@jabber.ru    http://www.amdmi3.ru
Comment 4 Christian Sturm 2008-10-14 13:40:35 UTC
You wrote:
> > Synopsis: Update biology/avida to 2.8.1
> >
> > http://www.freebsd.org/cgi/query-pr.cgi?pr=128057
>
> Here's the update, could you please test it?

I still get the following error on an up to date (i386) FreeBSD 
7-stable system:

[ 57%] Building CXX object 
CMakeFiles/avidacore.dir/source/main/cTaskLib.o
/usr/ports/biology/avida/work/avida-src-2.8.1/source/main/cTaskLib.cc: 
In member function 'double cTaskLib::Task_Log2(cTaskContext&) 
const':
/usr/ports/biology/avida/work/avida-src-2.8.1/source/main/cTaskLib.cc:2507: 
error: 'log2' was not declared in this scope
*** Error code 1

Stop in /usr/ports/biology/avida/work/avida-src-2.8.1/build.
*** Error code 1

Stop in /usr/ports/biology/avida/work/avida-src-2.8.1/build.
*** Error code 1

Stop in /usr/ports/biology/avida/work/avida-src-2.8.1/build.
*** Error code 1

Stop in /usr/ports/biology/avida.

-- 
Christian Sturm
http://reezer.freeshell.org/
Comment 5 dfilter service freebsd_committer freebsd_triage 2008-10-23 15:13:47 UTC
amdmi3      2008-10-23 14:13:37 UTC

  FreeBSD ports repository

  Modified files:
    biology/avida        Makefile distinfo pkg-plist 
  Added files:
    biology/avida/files  patch-source-main-cTaskLib.cc 
  Log:
  - Update to 2.8.1
  
  PR:             128057
  Submitted by:   Christian Sturm <athaba at inode dot at>
  
  Revision  Changes    Path
  1.24      +16 -31    ports/biology/avida/Makefile
  1.6       +3 -3      ports/biology/avida/distinfo
  1.1       +12 -0     ports/biology/avida/files/patch-source-main-cTaskLib.cc (new)
  1.5       +11 -118   ports/biology/avida/pkg-plist
_______________________________________________
cvs-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/cvs-all
To unsubscribe, send any mail to "cvs-all-unsubscribe@freebsd.org"
Comment 6 Dmitry Marakasov freebsd_committer freebsd_triage 2008-10-23 15:13:55 UTC
State Changed
From-To: open->closed

Committed. Thanks!