Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/lang/lua lua/module.mk: Avoid compiling Lua 5.3 module...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/b7ae5e3fe7f6
branches:  trunk
changeset: 435677:b7ae5e3fe7f6
user:      nia <nia%pkgsrc.org@localhost>
date:      Sat Jul 11 15:30:52 2020 +0000

description:
lua/module.mk: Avoid compiling Lua 5.3 modules with -ansi

diffstat:

 lang/lua/module.mk |  10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diffs (22 lines):

diff -r 8133e6df4ea5 -r b7ae5e3fe7f6 lang/lua/module.mk
--- a/lang/lua/module.mk        Sat Jul 11 15:22:54 2020 +0000
+++ b/lang/lua/module.mk        Sat Jul 11 15:30:52 2020 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: module.mk,v 1.9 2020/07/11 15:14:30 nia Exp $
+# $NetBSD: module.mk,v 1.10 2020/07/11 15:30:52 nia Exp $
 #
 # This Makefile fragment is intended to be included by packages that
 # install Lua modules.
@@ -75,4 +75,12 @@
 LDFLAGS.Darwin+=       -bundle -undefined dynamic_lookup
 .endif
 
+.if ${_LUA_VERSION} != "51" && ${_LUA_VERSION} != "52"
+# Any Lua>=5.3 module using these flags is invalid,
+# since Lua 5.3 and newer require "long long".
+BUILDLINK_TRANSFORM+=  opt:-ansi:-std=c99
+BUILDLINK_TRANSFORM+=  opt:-std=c89:-std=c99
+BUILDLINK_TRANSFORM+=  opt:-std=c90:-std=c99
+.endif
+
 .endif  # LUA_MODULE_MK



Home | Main Index | Thread Index | Old Index