[aur-general] TU application: Daurnimator

Ivy Foster iff at escondida.tk
Tue Dec 11 20:47:31 UTC 2018


On 11 Dec 2018, at 12:10 pm -0800, Daurnimator wrote:
> On Tue, 11 Dec 2018 at 12:04, Robin Broda via aur-general <aur-general at archlinux.org> wrote:
> > On 12/11/18 9:00 PM, Daurnimator wrote:
> > > On Tue, 11 Dec 2018 at 11:45, Alad Wenter via aur-general <aur-general at archlinux.org> wrote:
> > >> 2. You have some AUR packages for LUA modules of your own making, yet
> > >> they hardcode gcc lines instead of using a Makefile. [1] (At least they
> > >> respect $CFLAGS and $LDFLAGS, I guess.) Why?

> > > The upstream packages do not ship a makefile; they "officially" only
> > > support luarocks for building.

> > You are upstream, you have the power to make a change for the better

> The problem is that there is no nice cross-platform makefile structure
> suitable for lua libraries.

> Each operating system/distro calls the lua shared library something
> different, they all have their own set of required and conflicting
> flags, they all have differing install locations and search paths!

Yikes!

One ugly but workable solution could be to conditionally set variables
in a Makefile. For instance:

        ifeq ($(OS),Windows_NT) # for Windows versions >= NT
                LUA := C:\Winders\Path\To\Lua.whatever
        else
                UNAME := $(shell uname -s)
                ifeq ($(UNAME),Linux)
                        LUA := ...
                endif
                ...
        endif

Granted, this likely duplicates some of the magic luarocks is doing,
but it would make things simpler for packaging.

Come to think of it, that seems like the sort of thing that could be
done once as boilerplate in, e.g., lua.mk, which you and other
luarines (lua-ites? luans? lua-ers?) could then include in future
Makefiles.

Just spitballing here; lua packaging is weird (-: .

Cheers,
Ivy ("escondida")
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 833 bytes
Desc: not available
URL: <https://lists.archlinux.org/pipermail/aur-general/attachments/20181211/8beabf5e/attachment.asc>


More information about the aur-general mailing list