summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLina Pezzella <j4rg0n@gentoo.org>2005-02-06 01:01:06 +0000
committerLina Pezzella <j4rg0n@gentoo.org>2005-02-06 01:01:06 +0000
commit1ff90622456e8b65e3d601aa13f8e08939289697 (patch)
tree8b21c036ba135fdbaa3bb6f153d5c08925cd0fa1 /dev-lang/lua
parentStable on alpha. (diff)
downloadgentoo-2-1ff90622456e8b65e3d601aa13f8e08939289697.tar.gz
gentoo-2-1ff90622456e8b65e3d601aa13f8e08939289697.tar.bz2
gentoo-2-1ff90622456e8b65e3d601aa13f8e08939289697.zip
Fix for Bug #65591. Unstable ppc-macos
(Portage version: 2.0.51-r15)
Diffstat (limited to 'dev-lang/lua')
-rw-r--r--dev-lang/lua/ChangeLog9
-rw-r--r--dev-lang/lua/files/lua-ppc-macos-Makefile.patch185
-rw-r--r--dev-lang/lua/lua-4.0.1.ebuild4
-rw-r--r--dev-lang/lua/lua-4.0.ebuild4
-rw-r--r--dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild4
-rw-r--r--dev-lang/lua/lua-5.0.2-r1.ebuild4
-rw-r--r--dev-lang/lua/lua-5.0.2.ebuild57
-rw-r--r--dev-lang/lua/lua-5.0.ebuild4
8 files changed, 242 insertions, 29 deletions
diff --git a/dev-lang/lua/ChangeLog b/dev-lang/lua/ChangeLog
index 15529c5e19da..c051dc7a55c7 100644
--- a/dev-lang/lua/ChangeLog
+++ b/dev-lang/lua/ChangeLog
@@ -1,6 +1,11 @@
# ChangeLog for dev-lang/lua
-# Copyright 2002-2004 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/ChangeLog,v 1.32 2004/12/29 22:01:11 ciaranm Exp $
+# Copyright 2002-2005 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/ChangeLog,v 1.33 2005/02/06 01:01:06 j4rg0n Exp $
+
+ 05 Feb 2005; Lina Pezzella <j4rg0n@gentoo.org>
+ +files/lua-ppc-macos-Makefile.patch, lua-5.0.2.ebuild:
+ Unstable ppc-macos
+ Fix for Bug #65591
29 Dec 2004; Ciaran McCreesh <ciaranm@gentoo.org> :
Change encoding to UTF-8 for GLEP 31 compliance
diff --git a/dev-lang/lua/files/lua-ppc-macos-Makefile.patch b/dev-lang/lua/files/lua-ppc-macos-Makefile.patch
new file mode 100644
index 000000000000..4434862ccdbe
--- /dev/null
+++ b/dev-lang/lua/files/lua-ppc-macos-Makefile.patch
@@ -0,0 +1,185 @@
+diff -Naur lua-5.0.2/Makefile lua-5.0.2-new/Makefile
+--- lua-5.0.2/Makefile Sat Feb 5 14:33:58 2005
++++ lua-5.0.2-new/Makefile Sat Feb 5 14:36:07 2005
+@@ -22,7 +22,10 @@
+
+ # simple test to see Lua working
+ test: all
+- bin/lua test/hello.lua
++ @for ltest in `ls test/*.lua | grep -v life.lua`; do \
++ echo "Running $$ltest ..."; \
++ bin/lua $$ltest; \
++ done
+
+ # remove debug information from binaries
+ strip:
+@@ -30,11 +33,11 @@
+
+ # official installation
+ install: all strip
+- mkdir -p $(INSTALL_BIN) $(INSTALL_INC) $(INSTALL_LIB) $(INSTALL_MAN)
+- $(INSTALL_EXEC) bin/* $(INSTALL_BIN)
+- $(INSTALL_DATA) include/*.h $(INSTALL_INC)
+- $(INSTALL_DATA) lib/*.a $(INSTALL_LIB)
+- $(INSTALL_DATA) doc/*.1 $(INSTALL_MAN)
++ mkdir -p $(DESTDIR)$(INSTALL_BIN) $(DESTDIR)$(INSTALL_INC) $(DESTDIR)$(INSTALL_LIB) $(DESTDIR)$(INSTALL_MAN)
++ $(INSTALL_EXEC) bin/* $(DESTDIR)$(INSTALL_BIN)
++ $(INSTALL_DATA) include/*.h $(DESTDIR)$(INSTALL_INC)
++ $(INSTALL_DATA) lib/*.a $(DESTDIR)$(INSTALL_LIB)
++ $(INSTALL_DATA) doc/*.1 $(DESTDIR)$(INSTALL_MAN)
+
+ # shared libraries (for Linux)
+ so:
+@@ -42,21 +45,35 @@
+ gcc -o lib/liblualib.so.$V -shared src/lib/*.o
+ cd lib; ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
+
++# shared libraries (for Darwin)
++dylib:
++ $(CC) -dynamiclib -flat_namespace -undefined suppress -o lib/liblua.$V.$@ src/*.o -install_name $(INSTALL_LIB)/liblua.$V.$@ -compatibility_version $V -current_version $V
++ $(CC) -dynamiclib -flat_namespace -undefined suppress -o lib/liblualib.$V.$@ src/lib/*.o -install_name $(INSTALL_LIB)/liblualib.$V.$@ -compatibility_version $V -current_version $V
++ cd lib; ln -fs liblua.$V.$@ liblua.$@; ln -fs liblualib.$V.$@ liblualib.$@; ln -fs liblua.$V.$@ liblua.$(V:%.0=%).$@; ln -fs liblualib.$V.$@ liblualib.$(V:%.0=%).$@
++
+ # binaries using shared libraries
+-sobin:
++sobin dylibbin:
+ rm -f bin/*
+ cd src/lua; $(MAKE)
+ cd src/luac; $(MAKE)
+
+ # install shared libraries
+ soinstall:
+- $(INSTALL_EXEC) lib/*.so.* $(INSTALL_LIB)
+- cd $(INSTALL_LIB); ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
++ $(INSTALL_EXEC) lib/*.so.* $(DESTDIR)$(INSTALL_LIB)
++ cd $(DESTDIR)$(INSTALL_LIB); ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
++
++dylibinstall:
++ $(INSTALL_EXEC) lib/*.dylib $(DESTDIR)$(INSTALL_LIB)/
++ cd $(DESTDIR)$(INSTALL_LIB)/; ln -fs liblua.$V.dylib liblua.dylib; ln -fs liblualib.$V.dylib liblualib.dylib
++ cd $(DESTDIR)$(INSTALL_LIB)/; ln -fs liblua.$V.dylib liblua.$(V:%.0=%).dylib; ln -fs liblualib.$V.dylib liblualib.$(V:%.0=%).dylib
+
+ # clean shared libraries
+ soclean:
+ rm -f lib/*.so* bin/*
+
++dylibclean:
++ rm -f lib/*.dylib bin/*
++
+ # echo config parameters
+ echo:
+ @echo ""
+@@ -77,6 +94,7 @@
+ @echo "AR = $(AR)"
+ @echo "RANLIB = $(RANLIB)"
+ @echo "STRIP = $(STRIP)"
++ @echo "DESTDIR = $(DESTDIR)"
+ @echo "INSTALL_ROOT = $(INSTALL_ROOT)"
+ @echo "INSTALL_BIN = $(INSTALL_BIN)"
+ @echo "INSTALL_INC = $(INSTALL_INC)"
+diff -Naur lua-5.0.2/Makefile.orig lua-5.0.2-new/Makefile.orig
+--- lua-5.0.2/Makefile.orig Wed Dec 31 19:00:00 1969
++++ lua-5.0.2-new/Makefile.orig Sat Feb 5 14:35:42 2005
+@@ -0,0 +1,102 @@
++# makefile for Lua hierarchy
++# see INSTALL for installation instructions
++# see config for customization instructions
++
++LUA= .
++
++include $(LUA)/config
++
++# primary targets ("co" and "klean" are used for making the distribution)
++all clean co klean: dirs
++ cd include; $(MAKE) $@
++ cd src; $(MAKE) $@
++ cd src/lib; $(MAKE) $@
++ cd src/luac; $(MAKE) $@
++ cd src/lua; $(MAKE) $@
++
++# in case they were not created during unpacking
++dirs: bin lib
++
++bin lib:
++ mkdir -p $@
++
++# simple test to see Lua working
++test: all
++ bin/lua test/hello.lua
++
++# remove debug information from binaries
++strip:
++ $(STRIP) bin/*
++
++# official installation
++install: all strip
++ mkdir -p $(INSTALL_BIN) $(INSTALL_INC) $(INSTALL_LIB) $(INSTALL_MAN)
++ $(INSTALL_EXEC) bin/* $(INSTALL_BIN)
++ $(INSTALL_DATA) include/*.h $(INSTALL_INC)
++ $(INSTALL_DATA) lib/*.a $(INSTALL_LIB)
++ $(INSTALL_DATA) doc/*.1 $(INSTALL_MAN)
++
++# shared libraries (for Linux)
++so:
++ gcc -o lib/liblua.so.$V -shared src/*.o
++ gcc -o lib/liblualib.so.$V -shared src/lib/*.o
++ cd lib; ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
++
++# binaries using shared libraries
++sobin:
++ rm -f bin/*
++ cd src/lua; $(MAKE)
++ cd src/luac; $(MAKE)
++
++# install shared libraries
++soinstall:
++ $(INSTALL_EXEC) lib/*.so.* $(INSTALL_LIB)
++ cd $(INSTALL_LIB); ln -fs liblua.so.$V liblua.so; ln -fs liblualib.so.$V liblualib.so
++
++# clean shared libraries
++soclean:
++ rm -f lib/*.so* bin/*
++
++# echo config parameters
++echo:
++ @echo ""
++ @echo "These are the parameters currently set in $(LUA)/config to build Lua $V:"
++ @echo ""
++ @echo "LOADLIB = $(LOADLIB)"
++ @echo "DLLIB = $(DLLIB)"
++ @echo "NUMBER = $(NUMBER)"
++ @echo "POPEN = $(POPEN)"
++ @echo "TMPNAM = $(TMPNAM)"
++ @echo "DEGREES = $(DEGREES)"
++ @echo "USERCONF = $(USERCONF)"
++ @echo "CC = $(CC)"
++ @echo "WARN = $(WARN)"
++ @echo "MYCFLAGS = $(MYCFLAGS)"
++ @echo "MYLDFLAGS = $(MYLDFLAGS)"
++ @echo "EXTRA_LIBS = $(EXTRA_LIBS)"
++ @echo "AR = $(AR)"
++ @echo "RANLIB = $(RANLIB)"
++ @echo "STRIP = $(STRIP)"
++ @echo "INSTALL_ROOT = $(INSTALL_ROOT)"
++ @echo "INSTALL_BIN = $(INSTALL_BIN)"
++ @echo "INSTALL_INC = $(INSTALL_INC)"
++ @echo "INSTALL_LIB = $(INSTALL_LIB)"
++ @echo "INSTALL_MAN = $(INSTALL_MAN)"
++ @echo "INSTALL_EXEC = $(INSTALL_EXEC)"
++ @echo "INSTALL_DATA = $(INSTALL_DATA)"
++ @echo ""
++ @echo "Edit $(LUA)/config if needed to suit your platform and then run make."
++ @echo ""
++
++# turn config into Lua code
++# uncomment the last sed expression if you want nil instead of empty strings
++lecho:
++ @echo "-- $(LUA)/config for Lua $V"
++ @echo "VERSION = '$(V)'"
++ @make echo | grep = | sed -e 's/= /= "/' -e 's/$$/"/' #-e 's/""/nil/'
++ @echo "-- EOF"
++
++newer:
++ @find . -newer MANIFEST -type f
++
++# (end of Makefile)
diff --git a/dev-lang/lua/lua-4.0.1.ebuild b/dev-lang/lua/lua-4.0.1.ebuild
index 0b182e5f6357..982ef559e5be 100644
--- a/dev-lang/lua/lua-4.0.1.ebuild
+++ b/dev-lang/lua/lua-4.0.1.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-4.0.1.ebuild,v 1.10 2004/07/02 04:28:03 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-4.0.1.ebuild,v 1.11 2005/02/06 01:01:06 j4rg0n Exp $
inherit eutils
diff --git a/dev-lang/lua/lua-4.0.ebuild b/dev-lang/lua/lua-4.0.ebuild
index d4370e5c848e..be60658cacdb 100644
--- a/dev-lang/lua/lua-4.0.ebuild
+++ b/dev-lang/lua/lua-4.0.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-4.0.ebuild,v 1.16 2004/07/02 04:28:03 eradicator Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-4.0.ebuild,v 1.17 2005/02/06 01:01:06 j4rg0n Exp $
inherit eutils
diff --git a/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild b/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild
index ae7c63bb1a48..28bd2d1f48a7 100644
--- a/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild
+++ b/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild,v 1.6 2004/06/24 22:51:23 agriffis Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.1_beta20031003-r2.ebuild,v 1.7 2005/02/06 01:01:06 j4rg0n Exp $
inherit eutils
diff --git a/dev-lang/lua/lua-5.0.2-r1.ebuild b/dev-lang/lua/lua-5.0.2-r1.ebuild
index 2299b97231a0..3b64da0a0666 100644
--- a/dev-lang/lua/lua-5.0.2-r1.ebuild
+++ b/dev-lang/lua/lua-5.0.2-r1.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.2-r1.ebuild,v 1.2 2004/08/06 19:36:46 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.2-r1.ebuild,v 1.3 2005/02/06 01:01:06 j4rg0n Exp $
inherit eutils
diff --git a/dev-lang/lua/lua-5.0.2.ebuild b/dev-lang/lua/lua-5.0.2.ebuild
index df27ab27ced7..1a5397ba10bb 100644
--- a/dev-lang/lua/lua-5.0.2.ebuild
+++ b/dev-lang/lua/lua-5.0.2.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.2.ebuild,v 1.10 2004/09/05 18:36:54 gmsoft Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.2.ebuild,v 1.11 2005/02/06 01:01:06 j4rg0n Exp $
inherit eutils
@@ -10,7 +10,7 @@ SRC_URI="http://www.lua.org/ftp/${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
-KEYWORDS="alpha hppa ~mips ppc sparc x86 amd64 ppc64"
+KEYWORDS="alpha hppa ~mips ppc sparc x86 amd64 ppc64 ~ppc-macos"
IUSE="readline"
DEPEND=">=sys-apps/sed-4
@@ -20,17 +20,20 @@ src_unpack() {
unpack ${A}
epatch ${FILESDIR}/lua-${PV}-pic.patch
+ use ppc-macos && epatch ${FILESDIR}/lua-ppc-macos-Makefile.patch
cd ${S}
- sed -i config \
- -e 's:^#\(LOADLIB= -DUSE_DLOPEN=1\):\1:' \
- -e 's:^#\(DLLIB= -ldl\):\1:' \
- -e 's:^#\(MYLDFLAGS= -Wl,-E\):\1:' \
- -e 's:^#\(POPEN= -DUSE_POPEN=1\)$:\1:' \
- -e "s:^\(MYCFLAGS= \)-O2:\1${CFLAGS}:" \
- -e 's:^\(INSTALL_ROOT= \)/usr/local:\1$(DESTDIR)/usr:' \
- -e 's:^\(INSTALL_MAN= $(INSTALL_ROOT)\)/man/man1:\1/share/man/man1:'
+ if ! use ppc-macos; then
+ sed -i config \
+ -e 's:^#\(LOADLIB= -DUSE_DLOPEN=1\):\1:' \
+ -e 's:^#\(DLLIB= -ldl\):\1:' \
+ -e 's:^#\(MYLDFLAGS= -Wl,-E\):\1:' \
+ -e 's:^#\(POPEN= -DUSE_POPEN=1\)$:\1:' \
+ -e "s:^\(MYCFLAGS= \)-O2:\1${CFLAGS}:" \
+ -e 's:^\(INSTALL_ROOT= \)/usr/local:\1$(DESTDIR)/usr:' \
+ -e 's:^\(INSTALL_MAN= $(INSTALL_ROOT)\)/man/man1:\1/share/man/man1:'
+ fi
sed -i doc/readme.html \
-e 's:\(/README\)\("\):\1.gz\2:g'
@@ -60,18 +63,38 @@ EOF
src_compile() {
export PICFLAGS=-fPIC
emake || die "emake failed"
- emake so || die "emake so failed"
+ if use ppc-macos; then
+ # OSX does not have so files.
+ emake dylib dylibbin || die "emake dylib failed"
+ else
+ emake so || die "emake so failed"
+ fi
}
src_install() {
- make DESTDIR=${D} install soinstall || die "make install soinstall failed"
+ if use ppc-macos; then
+ # OSX does not have so files.
+ make DESTDIR=${D} install dylibinstall || die "make install dylibinstall failed"
+ else
+ make DESTDIR=${D} install soinstall || die "make install soinstall failed"
+ fi
dodoc HISTORY UPDATE
dohtml doc/*.html doc/*.gif
- for i in `find . -name README -printf "%h\n"`; do
- docinto ${i#.}
- dodoc ${i}/README
- done
+
+ if use ppc-macos; then
+ # -printf is not cross-platform, perhaps we could make this global, as it works on linux too.
+ for i in `find . -name README -exec dirname '{}' \;`; do
+ docinto ${i#.}
+ dodoc ${i}/README
+ done
+ else
+ # The original linux-only version
+ for i in `find . -name README -printf "%h\n"`; do
+ docinto ${i#.}
+ dodoc ${i}/README
+ done
+ fi
insinto /usr/share/lua
doins etc/compat.lua
diff --git a/dev-lang/lua/lua-5.0.ebuild b/dev-lang/lua/lua-5.0.ebuild
index f02eeb063444..ee56ad7c418e 100644
--- a/dev-lang/lua/lua-5.0.ebuild
+++ b/dev-lang/lua/lua-5.0.ebuild
@@ -1,6 +1,6 @@
-# Copyright 1999-2004 Gentoo Foundation
+# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.ebuild,v 1.10 2004/06/24 22:51:23 agriffis Exp $
+# $Header: /var/cvsroot/gentoo-x86/dev-lang/lua/lua-5.0.ebuild,v 1.11 2005/02/06 01:01:06 j4rg0n Exp $
DESCRIPTION="A powerful light-weight programming language designed for extending applications"
HOMEPAGE="http://www.lua.org/"