Bug 229866 - devel/lua-lpeg: broken due to wrong CFLAGS
Summary: devel/lua-lpeg: broken due to wrong CFLAGS
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: --- Affects Some People
Assignee: Po-Chuan Hsieh
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-07-18 15:07 UTC by Andrew "RhodiumToad" Gierth
Modified: 2018-07-29 19:34 UTC (History)
0 users

See Also:
bugzilla: maintainer-feedback? (sunpoet)


Attachments
patch for lua-lpeg/Makefile (672 bytes, patch)
2018-07-18 15:07 UTC, Andrew "RhodiumToad" Gierth
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Andrew "RhodiumToad" Gierth 2018-07-18 15:07:36 UTC
Created attachment 195247 [details]
patch for lua-lpeg/Makefile

This port defines -DLUA_32BITS in CFLAGS, which guarantees that it will fail to load when using any standard Lua build (whether from ports or upstream).

(LUA_32BITS is a non-standard compile option to Lua that forces the use of 32-bit integers AND 32-bit floats as the (only) numeric types; this option is not useful except on platforms with no 64-bit support at all. As this changes the Lua ABI, it makes /absolutely no sense/ to set this in a module build; the module should pick up the value from luaconf.h.)

Also, it fails to install the re.lua module, which is probably the most commonly-used interface to lpeg.

% lua53
Lua 5.3.4  Copyright (C) 1994-2017 Lua.org, PUC-Rio
> require 'lpeg'
core and library have incompatible numeric types

Patch attached.
Comment 1 commit-hook freebsd_committer freebsd_triage 2018-07-29 19:29:50 UTC
A commit references this bug:

Author: sunpoet
Date: Sun Jul 29 19:28:34 UTC 2018
New revision: 475849
URL: https://svnweb.freebsd.org/changeset/ports/475849

Log:
  Remove incorrect CFLAGS

  - Install re.lua
  - Bump PORTREVISION for package change

  PR:		229866
  Submitted by:	Andrew Gierth <andrew@tao11.riddles.org.uk>

Changes:
  head/devel/lua-lpeg/Makefile