pkgsrc-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[pkgsrc/trunk]: pkgsrc/lang/lua Add module.mk for Lua packages.
details: https://anonhg.NetBSD.org/pkgsrc/rev/22637d4842e2
branches: trunk
changeset: 552922:22637d4842e2
user: minskim <minskim%pkgsrc.org@localhost>
date: Sun Jan 11 23:15:55 2009 +0000
description:
Add module.mk for Lua packages.
Suggested by Aleksey Cheusov on pkgsrc-users@.
diffstat:
lang/lua/Makefile | 6 ++++--
lang/lua/module.mk | 28 ++++++++++++++++++++++++++++
lang/lua/version.mk | 6 ++++++
3 files changed, 38 insertions(+), 2 deletions(-)
diffs (63 lines):
diff -r eb1ad98b0d89 -r 22637d4842e2 lang/lua/Makefile
--- a/lang/lua/Makefile Sun Jan 11 22:50:58 2009 +0000
+++ b/lang/lua/Makefile Sun Jan 11 23:15:55 2009 +0000
@@ -1,6 +1,6 @@
-# $NetBSD: Makefile,v 1.38 2008/09/07 14:03:42 wiz Exp $
+# $NetBSD: Makefile,v 1.39 2009/01/11 23:15:55 minskim Exp $
-DISTNAME= lua-5.1.4
+DISTNAME= lua-${LUA_VERSION}
CATEGORIES= lang
MASTER_SITES= ftp://ftp.tecgraf.puc-rio.br/pub/lua/ \
ftp://ftp.gwdg.de/pub/languages/lua/ \
@@ -16,6 +16,8 @@
HOMEPAGE= http://www.lua.org/
COMMENT= Powerful light-weight language for extending applications
+.include "../../lang/lua/version.mk"
+
PKG_INSTALLATION_TYPES= overwrite pkgviews
PKG_DESTDIR_SUPPORT= user-destdir
diff -r eb1ad98b0d89 -r 22637d4842e2 lang/lua/module.mk
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/lua/module.mk Sun Jan 11 23:15:55 2009 +0000
@@ -0,0 +1,28 @@
+# $NetBSD: module.mk,v 1.1 2009/01/11 23:15:55 minskim Exp $
+#
+# This Makefile fragment is intended to be included by packages that
+# install Lua packages.
+
+.if !defined(LUA_MODULE_MK)
+LUA_MODULE_MK= # defined
+
+.include "../../lang/lua/version.mk"
+
+_LUA_VERSION= ${LUA_VERSION_MAJOR}.${LUA_VERSION_MINOR}
+
+LUA_PKGPREFIX= lua
+LUA_LDIR= share/lua/${_LUA_VERSION}
+PLIST_SUBST+= LUA_LDIR=${LUA_LDIR}
+
+.if defined(NO_BUILD) && empty(NO_BUILD:M[Nn][Oo])
+DEPENDS+= lua-${_LUA_VERSION}.*:../../lang/lua
+.else
+LUA_CDIR= lib/lua/${_LUA_VERSION}
+PLIST_SUBST+= LUA_CDIR=${LUA_CDIR}
+
+BUILDLINK_API_DEPENDS.lua+= lua-${_LUA_VERSION}.*
+
+.include "../../lang/lua/buildlink3.mk"
+.endif
+
+.endif # LUA_MODULE_MK
diff -r eb1ad98b0d89 -r 22637d4842e2 lang/lua/version.mk
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/lang/lua/version.mk Sun Jan 11 23:15:55 2009 +0000
@@ -0,0 +1,6 @@
+# $NetBSD: version.mk,v 1.1 2009/01/11 23:15:55 minskim Exp $
+
+LUA_VERSION= 5.1.4
+
+LUA_VERSION_MAJOR= ${LUA_VERSION:C/([0-9]+)\.([0-9]+)\.([0-9]+)/\1/}
+LUA_VERSION_MINOR= ${LUA_VERSION:C/([0-9]+)\.([0-9]+)\.([0-9]+)/\2/}
Home |
Main Index |
Thread Index |
Old Index