[90148] trunk/dports/lang

Ryan Schmidt ryandesign at macports.org
Fri Feb 24 08:09:30 PST 2012


On Feb 24, 2012, at 02:41, pvanek at macports.org wrote:

> Revision: 90148
>          http://trac.macports.org/changeset/90148
> Author:   pvanek at macports.org
> Date:     2012-02-24 00:41:23 -0800 (Fri, 24 Feb 2012)
> Log Message:
> -----------
> new port qore-devel


> Added: trunk/dports/lang/qore-devel/Portfile
> ===================================================================
> --- trunk/dports/lang/qore-devel/Portfile	                        (rev 0)
> +++ trunk/dports/lang/qore-devel/Portfile	2012-02-24 08:41:23 UTC (rev 90148)

This port should have been created by "svn copy"ing the qore port; that way the output of "svn log" and "svn blame" would not give the mistaken impression that this portfile was written today from scratch.


> +name                qore-devel
> +version             0.8.3.99

> +svn.url             https://qore.svn.sourceforge.net/svnroot/qore/qore/trunk/

It is not ok for a port to fetch directly from the HEAD of trunk. Fetch from a specific revision of trunk instead -- whatever revision corresponds to version "0.8.3.99". If no such correspondence exists, you may want to revise your version line to include the date or svn revision number, to be able to differentiate it if/when you later increase the svn revision number.


> +pre-configure {
> +    # small set of hacks here. reconf.sh is mandatory for svn builds. The svn-revision.h is real hack as I don't know why it is not crated automatically. (pvanek)
> +    system "cd ${worksrcpath}; ./reconf.sh; echo \"#define BUILD 0\" > ${worksrcpath}/include/qore/intern/svn-revision.h"
> +}

reconf.sh runs glibtoolize, aclocal, autoconf, autoheader and automake. As such, you need build dependencies on the ports libtool, autoconf and automake.

The reason why you are manually creating svn-revision.h is presumably to avoid the error message "QoreLib.cpp:24:38: error: qore/intern/svn-revision.h: No such file or directory". And the reason that file doesn't get generated is presumably that it relies on the directory being a Subversion working copy. But by default MacPorts creates a Subversion export, not a working copy. You can get a working copy by using "svn.method checkout", however if echoing "#define BUILD 0" into the file is equivalent, then that seems better, since a working copy will use twice as much disk space as an export.

Note that "system" has a "-W" argument available now (just like "xinstall" does) so you don't have to manually "cd" anymore.


Attached is a patch that makes these changes. Ideally you would make a local copy of the qore-devel portfile, delete the port directory and commit; re-create the port directory by "svn copy"ing the qore port directory and replacing the portfile with your local copy and commit; then apply my patch and commit.

-------------- next part --------------
A non-text attachment was scrubbed...
Name: qore-devel.diff
Type: application/octet-stream
Size: 1542 bytes
Desc: not available
URL: <http://lists.macosforge.org/pipermail/macports-dev/attachments/20120224/4d80e5a3/attachment.obj>


More information about the macports-dev mailing list