[52918] trunk/dports/graphics/freeimage
toby at macports.org
toby at macports.org
Thu Jun 25 13:39:28 PDT 2009
Revision: 52918
http://trac.macports.org/changeset/52918
Author: toby at macports.org
Date: 2009-06-25 13:39:27 -0700 (Thu, 25 Jun 2009)
Log Message:
-----------
#20078 (freeimage update and build cleanup)
Take maintainership, with previous maintainer's approval.
Modified Paths:
--------------
trunk/dports/graphics/freeimage/Portfile
Added Paths:
-----------
trunk/dports/graphics/freeimage/files/patch-Makefile.gnu
Removed Paths:
-------------
trunk/dports/graphics/freeimage/files/patch-Makefile.osx-Leopard.diff
Modified: trunk/dports/graphics/freeimage/Portfile
===================================================================
--- trunk/dports/graphics/freeimage/Portfile 2009-06-25 20:25:06 UTC (rev 52917)
+++ trunk/dports/graphics/freeimage/Portfile 2009-06-25 20:39:27 UTC (rev 52918)
@@ -4,9 +4,9 @@
PortSystem 1.0
name freeimage
-version 3.10.0
+version 3.12.0
categories graphics
-maintainers ryand-ruby at zenspider.com
+maintainers toby
description Library for FreeImage, a dependency-less graphics library
long_description FreeImage is a library for developers who would like to \
support most popular graphics image formats. Some \
@@ -19,25 +19,27 @@
use_zip yes
worksrcdir FreeImage
-checksums md5 2e57135e26bb487cc8e13ee7b7e0a595 \
- sha1 9590563e8abade9494fc6db6f6127fa3db42b8e1 \
- rmd160 9f501e099bca567b2ffedd0f9f00ad6b58021b09
+checksums md5 47b259102f776a4bcd7affc00942f3b4 \
+ sha1 d9a5efc9590cb45e176c7e5552afef961594a1cb \
+ rmd160 421ddbd81343d14561ade844c67c31802ab444ad
-use_configure no
+patchfiles patch-Makefile.gnu
-destroot.pre_args -f Makefile.osx ${destroot.target}
-destroot.destdir PREFIX=${destroot}${prefix}
+configure {
+ reinplace "s|__PREFIX__|${prefix}|" ${worksrcpath}/Makefile.gnu
-default_variants +universal
-variant universal {}
-pre-fetch {
- if {![variant_isset universal]} {
- return -code error "${name} is only available in a universal version"
- }
-}
+ reinplace "s|__LDFLAGS__|${configure.ldflags}|" ${worksrcpath}/Makefile.gnu
-platform darwin 9 {
- patchfiles-append patch-Makefile.osx-Leopard.diff
+ reinplace "s|__CC__|${configure.cc}|" ${worksrcpath}/Makefile.gnu
+ reinplace "s|__CFLAGS__|${configure.cflags}|" ${worksrcpath}/Makefile.gnu
+
+ reinplace "s|__CXX__|${configure.cxx}|" ${worksrcpath}/Makefile.gnu
+ reinplace "s|__CXXFLAGS__|${configure.cxxflags}|" ${worksrcpath}/Makefile.gnu
}
+build.target FreeImage
+build.args -f Makefile.gnu
+
+destroot.args -f Makefile.gnu
+
livecheck.regex <title>Source Distribution (.*) released.*</title>
Added: trunk/dports/graphics/freeimage/files/patch-Makefile.gnu
===================================================================
--- trunk/dports/graphics/freeimage/files/patch-Makefile.gnu (rev 0)
+++ trunk/dports/graphics/freeimage/files/patch-Makefile.gnu 2009-06-25 20:39:27 UTC (rev 52918)
@@ -0,0 +1,69 @@
+--- Makefile.gnu.orig 2009-06-24 17:19:47.000000000 -0700
++++ Makefile.gnu 2009-06-24 17:57:28.000000000 -0700
+@@ -3,10 +3,14 @@
+ # This file can be generated by ./gensrclist.sh
+ include Makefile.srcs
+
++CC = __CC__
++CXX = __CXX__
++LDFLAGS = __LDFLAGS__
++
+ # General configuration variables:
+-DESTDIR ?= /
+-INCDIR ?= $(DESTDIR)/usr/include
+-INSTALLDIR ?= $(DESTDIR)/usr/lib
++DESTDIR ?=
++INCDIR ?= $(DESTDIR)__PREFIX__/include
++INSTALLDIR ?= $(DESTDIR)__PREFIX__/lib
+
+ # Converts cr/lf to just lf
+ DOS2UNIX = dos2unix
+@@ -15,9 +19,9 @@
+
+ MODULES = $(SRCS:.c=.o)
+ MODULES := $(MODULES:.cpp=.o)
+-CFLAGS ?= -O3 -fPIC -fexceptions -fvisibility=hidden
++CFLAGS ?= __CFLAGS__ -fPIC -fexceptions -fvisibility=hidden
+ CFLAGS += $(INCLUDE)
+-CXXFLAGS ?= -O3 -fPIC -fexceptions -fvisibility=hidden -Wno-ctor-dtor-privacy
++CXXFLAGS ?= __CXXFLAGS__ -fPIC -fexceptions -fvisibility=hidden -Wno-ctor-dtor-privacy
+ CXXFLAGS += $(INCLUDE)
+
+ ifeq ($(shell sh -c 'uname -m 2>/dev/null || echo not'),x86_64)
+@@ -27,9 +31,9 @@
+
+ TARGET = freeimage
+ STATICLIB = lib$(TARGET).a
+-SHAREDLIB = lib$(TARGET)-$(VER_MAJOR).$(VER_MINOR).so
+-LIBNAME = lib$(TARGET).so
+-VERLIBNAME = $(LIBNAME).$(VER_MAJOR)
++SHAREDLIB = lib$(TARGET).$(VER_MAJOR).$(VER_MINOR).dylib
++LIBNAME = lib$(TARGET).dylib
++VERLIBNAME = lib$(TARGET).$(VER_MAJOR).dylib
+ HEADER = Source/FreeImage.h
+
+
+@@ -55,16 +59,18 @@
+ $(CXX) $(CXXFLAGS) -c $< -o $@
+
+ $(STATICLIB): $(MODULES)
+- $(AR) r $@ $(MODULES)
++ /usr/bin/libtool -o $@ $(MODULES)
+
+ $(SHAREDLIB): $(MODULES)
+- $(CC) -shared -Wl,-soname,$(VERLIBNAME) $(LDFLAGS) -o $@ $(MODULES) $(LIBRARIES)
++ $(CC) -dynamiclib -install_name $(INSTALLDIR)/$(VERLIBNAME) -compatibility_version $(VER_MAJOR) -current_version $(VER_MAJOR).$(VER_MINOR) $(LDFLAGS) -o $@ $(MODULES) $(LIBRARIES)
+
+ install:
+ install -d $(INCDIR) $(INSTALLDIR)
+- install -m 644 -o root -g root $(HEADER) $(INCDIR)
+- install -m 644 -o root -g root $(STATICLIB) $(INSTALLDIR)
+- install -m 755 -o root -g root $(SHAREDLIB) $(INSTALLDIR)
++ install -m 644 $(HEADER) $(INCDIR)
++ install -m 644 $(STATICLIB) $(INSTALLDIR)
++ install -m 755 $(SHAREDLIB) $(INSTALLDIR)
++ ln -s $(SHAREDLIB) $(INSTALLDIR)/$(VERLIBNAME)
++ ln -s $(SHAREDLIB) $(INSTALLDIR)/$(LIBNAME)
+
+ clean:
+ rm -f core Dist/*.* u2dtmp* $(MODULES) $(STATICLIB) $(SHAREDLIB) $(LIBNAME)
Deleted: trunk/dports/graphics/freeimage/files/patch-Makefile.osx-Leopard.diff
===================================================================
--- trunk/dports/graphics/freeimage/files/patch-Makefile.osx-Leopard.diff 2009-06-25 20:25:06 UTC (rev 52917)
+++ trunk/dports/graphics/freeimage/files/patch-Makefile.osx-Leopard.diff 2009-06-25 20:39:27 UTC (rev 52918)
@@ -1,20 +0,0 @@
---- Makefile.osx.orig 2007-08-25 17:00:38.000000000 +0200
-+++ Makefile.osx 2008-02-15 15:41:15.000000000 +0100
-@@ -14,14 +14,14 @@
- COMPILERFLAGS_I386 = -arch i386
- COMPILERPPFLAGS = -Wno-ctor-dtor-privacy
- INCLUDE +=
--INCLUDE_PPC = -isysroot /Developer/SDKs/MacOSX10.3.9.sdk
-+INCLUDE_PPC = -isysroot /Developer/SDKs/MacOSX10.4u.sdk
- INCLUDE_I386 = -isysroot /Developer/SDKs/MacOSX10.4u.sdk
- CFLAGS_PPC = $(COMPILERFLAGS) $(COMPILERFLAGS_PPC) $(INCLUDE) $(INCLUDE_PPC)
- CFLAGS_I386 = $(COMPILERFLAGS) $(COMPILERFLAGS_I386) $(INCLUDE) $(INCLUDE_I386)
- CPPFLAGS_PPC = $(COMPILERPPFLAGS) $(CFLAGS_PPC)
- CPPFLAGS_I386 = $(COMPILERPPFLAGS) $(CFLAGS_I386)
--LIBRARIES_PPC = -Wl,-syslibroot /Developer/SDKs/MacOSX10.3.9.sdk
--LIBRARIES_I386 = -Wl,-syslibroot /Developer/SDKs/MacOSX10.4u.sdk
-+LIBRARIES_PPC = -Wl,-syslibroot /Developer/SDKs/MacOSX10.4u.sdk/usr/lib
-+LIBRARIES_I386 = -Wl,-syslibroot /Developer/SDKs/MacOSX10.4u.sdk/usr/lib
- LIBTOOL = libtool
- LIPO = lipo
-
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macosforge.org/pipermail/macports-changes/attachments/20090625/81ffaa32/attachment.html>
More information about the macports-changes
mailing list