[103476] trunk/dports/lang/squirrel

larryv at macports.org larryv at macports.org
Tue Feb 26 15:29:26 PST 2013


Revision: 103476
          https://trac.macports.org/changeset/103476
Author:   larryv at macports.org
Date:     2013-02-26 15:29:26 -0800 (Tue, 26 Feb 2013)
Log Message:
-----------
squirrel: Update to 3.0.4 (#38195).

Also:
* Change license to MIT.
* Change master_sites to googlecode.
* Remove unnecessary reinplace.
* Make build respect arch and SDK.
* Add livecheck.

Modified Paths:
--------------
    trunk/dports/lang/squirrel/Portfile

Added Paths:
-----------
    trunk/dports/lang/squirrel/files/patch-Makefile.diff
    trunk/dports/lang/squirrel/files/patch-sq-Makefile.diff
    trunk/dports/lang/squirrel/files/patch-sqstdlib-Makefile.diff
    trunk/dports/lang/squirrel/files/patch-squirrel-Makefile.diff

Removed Paths:
-------------
    trunk/dports/lang/squirrel/files/patch-compiler.diff

Modified: trunk/dports/lang/squirrel/Portfile
===================================================================
--- trunk/dports/lang/squirrel/Portfile	2013-02-26 23:09:45 UTC (rev 103475)
+++ trunk/dports/lang/squirrel/Portfile	2013-02-26 23:29:26 UTC (rev 103476)
@@ -4,10 +4,10 @@
 PortSystem              1.0
 
 name                    squirrel
-version                 2.2.3
+version                 3.0.4
 categories              lang
 platforms               darwin
-license                 BSD
+license                 MIT
 maintainers             nomaintainer
 
 description             The Squirrel programming language
@@ -19,37 +19,43 @@
                         video games.
 homepage                http://www.squirrel-lang.org/
 
-master_sites            sourceforge
-distname                squirrel_${version}_stable
-checksums               md5     25295ed1459111a80f612357cfe83b54 \
-                        sha1    aa5a427edf1e1a7415414462d7a7773913eb8d60 \
-                        rmd160  597e219851957cfcd71d8e6aefeee73d8e01c569
+master_sites            googlecode
+distname                squirrel_[string map {. _} ${version}]_stable
+checksums               rmd160  0a60aa77d55b32839a16c4b954238a2b856ff4b4 \
+                        sha256  6a3706accf9872aafea1eb3f3f3018b135e2671033824ccebf0735a98b2440a5
 
-pre-patch {
-    reinplace "s|\r||g" \
-        ${worksrcpath}/sq/Makefile \
-        ${worksrcpath}/squirrel/Makefile \
-        ${worksrcpath}/sqstdlib/Makefile
-}
+worksrcdir              SQUIRREL[lindex [split ${version} .] 0]
 
-patchfiles              patch-compiler.diff
+patchfiles              patch-Makefile.diff \
+                        patch-sq-Makefile.diff \
+                        patch-sqstdlib-Makefile.diff \
+                        patch-squirrel-Makefile.diff
 
-worksrcdir              SQUIRREL2
-
 use_configure           no
 
-build.target            sq32
-build.env-append        CC=${configure.cc} \
+build.args              CC=${configure.cc} \
                         CXX=${configure.cxx}
 
+set cflags "[get_canonical_archflags cc]"
+set cxxflags "[get_canonical_archflags cxx]"
+set ldflags "[get_canonical_archflags ld]"
+if {${configure.sdkroot} != ""} {
+    set cflags "${cflags} -isysroot ${configure.sdkroot}"
+    set cxxflags "${cxxflags} -isysroot ${configure.sdkroot}"
+    set ldflags "${ldflags} -Wl,-syslibroot,${configure.sdkroot}"
+}
+build.args-append       CFLAGS="${cflags}" \
+                        CXXFLAGS="${cxxflags}" \
+                        LDFLAGS="${ldflags}"
+
 destroot {
-    xinstall -m 755 ${worksrcpath}/bin/sq ${destroot}${prefix}/bin
-    xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
-    file copy ${worksrcpath}/samples \
-        ${destroot}${prefix}/share/doc/${name}/examples
+    xinstall ${worksrcpath}/bin/sq ${destroot}${prefix}/bin
+    xinstall -d ${destroot}${prefix}/share/doc/${name}
+    copy ${worksrcpath}/samples ${destroot}${prefix}/share/doc/${name}/examples
     xinstall -m 644 -W ${worksrcpath}/lib libsqstdlib.a libsquirrel.a \
         ${destroot}${prefix}/lib
-    xinstall -m 644 -W ${worksrcpath}/include sqstdaux.h sqstdblob.h sqstdio.h \
-        sqstdmath.h sqstdstring.h sqstdsystem.h squirrel.h \
+    eval xinstall -m 644 -W ${worksrcpath}/include [glob *.h] \
         ${destroot}${prefix}/include
 }
+
+livecheck.version       [string map {. _} $version]

Added: trunk/dports/lang/squirrel/files/patch-Makefile.diff
===================================================================
--- trunk/dports/lang/squirrel/files/patch-Makefile.diff	                        (rev 0)
+++ trunk/dports/lang/squirrel/files/patch-Makefile.diff	2013-02-26 23:29:26 UTC (rev 103476)
@@ -0,0 +1,11 @@
+--- Makefile.orig	2006-03-05 11:03:53.000000000 -0500
++++ Makefile	2013-02-25 03:05:30.000000000 -0500
+@@ -2,7 +2,7 @@
+ SQUIRREL=.
+ MAKE=make
+ 
+-sq32:
++all:
+ 	cd squirrel; $(MAKE) 
+ 	cd sqstdlib; $(MAKE) 
+ 	cd sq; $(MAKE) 

Deleted: trunk/dports/lang/squirrel/files/patch-compiler.diff
===================================================================
--- trunk/dports/lang/squirrel/files/patch-compiler.diff	2013-02-26 23:09:45 UTC (rev 103475)
+++ trunk/dports/lang/squirrel/files/patch-compiler.diff	2013-02-26 23:29:26 UTC (rev 103476)
@@ -1,59 +0,0 @@
---- sq/Makefile.orig	2006-03-06 11:01:40.000000000 -0600
-+++ sq/Makefile	2009-11-15 00:49:01.000000000 -0600
-@@ -12,10 +12,10 @@
- 	
- 	
- sq32:
--	g++ -O2 -fno-rtti -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
-+	$(CXX) -O2 -fno-rtti -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
- 
- sqprof:
--	g++ -O2 -pg -fno-rtti -pie -gstabs -g3 -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
-+	$(CXX) -O2 -pg -fno-rtti -pie -gstabs -g3 -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
- 	
- sq64:
--	g++ -O2 -fno-rtti -D_SQ64 -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
-+	$(CXX) -O2 -fno-rtti -D_SQ64 -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
---- squirrel/Makefile.orig	2006-03-07 04:01:31.000000000 +1100
-+++ squirrel/Makefile	2008-05-10 17:04:29.000000000 +1000
-@@ -37,16 +37,16 @@
- 	
- 	
- sq32:
--	gcc -O2  -fno-rtti -Wall -c $(SRCS) $(INCZ) $(DEFS)
-+	$(CC) -O2  -fno-rtti -Wall -c $(SRCS) $(INCZ) $(DEFS)
- 	ar rc $(OUT) *.o
- 	rm *.o
- 
- sqprof:
--	gcc -O2 -pg -fno-rtti -pie -gstabs -g3 -Wall -c $(SRCS) $(INCZ) $(DEFS)
-+	$(CC) -O2 -pg -fno-rtti -pie -gstabs -g3 -Wall -c $(SRCS) $(INCZ) $(DEFS)
- 	ar rc $(OUT) *.o
- 	rm *.o
- 
- sq64:
--	gcc -O2  -D_SQ64 -fno-rtti -Wall -c $(SRCS) $(INCZ) $(DEFS)
-+	$(CC) -O2  -D_SQ64 -fno-rtti -Wall -c $(SRCS) $(INCZ) $(DEFS)
- 	ar rc $(OUT) *.o
- 	rm *.o
---- sqstdlib/Makefile.orig	2006-03-06 11:01:50.000000000 -0600
-+++ sqstdlib/Makefile	2009-11-15 00:33:22.000000000 -0600
-@@ -16,15 +16,15 @@
- 	
- 	
- sq32:
--	gcc -O2  -fno-rtti -Wall -c $(SRCS) $(INCZ)
-+	$(CC) -O2  -fno-rtti -Wall -c $(SRCS) $(INCZ)
- 	ar rc $(OUT) *.o
- 	rm *.o
- 
- sqprof:
--	gcc -O2 -pg -fno-rtti -pie -gstabs -g3 -Wall -c $(SRCS) $(INCZ)
-+	$(CC) -O2 -pg -fno-rtti -pie -gstabs -g3 -Wall -c $(SRCS) $(INCZ)
- 	ar rc $(OUT) *.o
- 	rm *.o
- sq64:
--	gcc -O2 -D_SQ64 -fno-rtti -Wall -c $(SRCS) $(INCZ)
-+	$(CC) -O2 -D_SQ64 -fno-rtti -Wall -c $(SRCS) $(INCZ)
- 	ar rc $(OUT) *.o
- 	rm *.o

Added: trunk/dports/lang/squirrel/files/patch-sq-Makefile.diff
===================================================================
--- trunk/dports/lang/squirrel/files/patch-sq-Makefile.diff	                        (rev 0)
+++ trunk/dports/lang/squirrel/files/patch-sq-Makefile.diff	2013-02-26 23:29:26 UTC (rev 103476)
@@ -0,0 +1,13 @@
+--- sq/Makefile.orig	2012-02-11 11:55:55.000000000 -0500
++++ sq/Makefile	2013-02-26 00:49:04.000000000 -0500
+@@ -11,8 +11,8 @@
+ SRCS= sq.c
+ 	
+ 	
+-sq32:
+-	g++ -O2 -s -fno-exceptions -fno-rtti -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
++all:
++	$(CXX) $(CXXFLAGS) $(LDFLAGS) -O2 -s -fno-exceptions -fno-rtti -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)
+ 
+ sqprof:
+ 	g++ -O2 -pg -fno-exceptions -fno-rtti -pie -gstabs -g3 -o $(OUT) $(SRCS) $(INCZ) $(LIBZ) $(LIB)

Added: trunk/dports/lang/squirrel/files/patch-sqstdlib-Makefile.diff
===================================================================
--- trunk/dports/lang/squirrel/files/patch-sqstdlib-Makefile.diff	                        (rev 0)
+++ trunk/dports/lang/squirrel/files/patch-sqstdlib-Makefile.diff	2013-02-26 23:29:26 UTC (rev 103476)
@@ -0,0 +1,13 @@
+--- sqstdlib/Makefile.orig	2011-04-09 16:56:42.000000000 -0400
++++ sqstdlib/Makefile	2013-02-26 00:52:31.000000000 -0500
+@@ -25,8 +25,8 @@
+ 	sqstdrex.cpp
+ 	
+ 	
+-sq32:
+-	gcc -O2 -fno-exceptions -fno-rtti -Wall -fno-strict-aliasing -c $(SRCS) $(INCZ)
++all:
++	$(CC) $(CFLAGS) -O2 -fno-exceptions -fno-rtti -Wall -fno-strict-aliasing -c $(SRCS) $(INCZ)
+ 	ar rc $(OUT) *.o
+ 	rm *.o
+ 

Added: trunk/dports/lang/squirrel/files/patch-squirrel-Makefile.diff
===================================================================
--- trunk/dports/lang/squirrel/files/patch-squirrel-Makefile.diff	                        (rev 0)
+++ trunk/dports/lang/squirrel/files/patch-squirrel-Makefile.diff	2013-02-26 23:29:26 UTC (rev 103476)
@@ -0,0 +1,13 @@
+--- squirrel/Makefile.orig	2012-02-11 11:56:02.000000000 -0500
++++ squirrel/Makefile	2013-02-26 00:56:10.000000000 -0500
+@@ -36,8 +36,8 @@
+ 
+ 	
+ 	
+-sq32:
+-	gcc -O2 -fno-exceptions -fno-rtti -Wall -fno-strict-aliasing -c $(SRCS) $(INCZ) $(DEFS)
++all:
++	$(CC) $(CFLAGS) -O2 -fno-exceptions -fno-rtti -Wall -fno-strict-aliasing -c $(SRCS) $(INCZ) $(DEFS)
+ 	ar rc $(OUT) *.o
+ 	rm *.o
+ 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20130226/62719bea/attachment-0001.html>


More information about the macports-changes mailing list