diff options
author | Alexander M Pickering <alex@cogarr.net> | 2024-07-29 16:32:59 -0500 |
---|---|---|
committer | Alexander M Pickering <alex@cogarr.net> | 2024-07-29 16:32:59 -0500 |
commit | ae3e8e4331852dc89479fba5c5175721bd27c20e (patch) | |
tree | 3039c85923db508e4caea8f7211ce2f4eae09abc | |
parent | c9180644003e24bc979f2194abd0c5353d58b766 (diff) | |
download | lua-packaging-ae3e8e4331852dc89479fba5c5175721bd27c20e.tar.gz lua-packaging-ae3e8e4331852dc89479fba5c5175721bd27c20e.tar.bz2 lua-packaging-ae3e8e4331852dc89479fba5c5175721bd27c20e.zip |
Start working on builds
-rwxr-xr-x | init | 10 | ||||
-rw-r--r-- | meta.lua | 49 |
2 files changed, 50 insertions, 9 deletions
@@ -1,2 +1,10 @@ | |||
1 | #!/bin/sh -ex | 1 | #!/bin/sh -ex |
2 | ls -lah | 2 | |
3 | luaver=$(ls lua-*.tar.gz | grep -Eo "lua-.\\..") | ||
4 | mkdir "$luaver" | ||
5 | tar -xvzf lua-*.tar.gz --directory="$luaver" --strip-components=1 | ||
6 | cd "$luaver" | ||
7 | make mingw "CFLAGS= -Wall -Wextra -std=c99 -pedantic $1 $2" | ||
8 | cd "/root/" | ||
9 | cp "$luaver/src/*.exe" . | ||
10 | cp "$luaver/src/*.dll" . | ||
@@ -1,11 +1,44 @@ | |||
1 | local lua_versions = {"5.1","5.2","5.3","5.4"} | 1 | local lua_versions = { |
2 | ["51"] = "https://www.lua.org/ftp/lua-5.1.5.tar.gz", | ||
3 | --[[ | ||
4 | ["52"] = "https://www.lua.org/ftp/lua-5.2.4.tar.gz", | ||
5 | ["53"] = "https://www.lua.org/ftp/lua-5.3.6.tar.gz", | ||
6 | ["54"] = "https://www.lua.org/ftp/lua-5.4.7.tar.gz", | ||
7 | ]] | ||
8 | } | ||
9 | local optimizations = { | ||
10 | size = "-Os", | ||
11 | --[[ | ||
12 | zero = "-O0", | ||
13 | one = "-O1", | ||
14 | two = "-O2", | ||
15 | three = "-O3", | ||
16 | ]] | ||
17 | } | ||
18 | local debug = { | ||
19 | release = "", | ||
20 | --[[ | ||
21 | debug = "-g", | ||
22 | ]] | ||
23 | } | ||
24 | local compilers = {--[["mingw32",]]"mingw64"--[[,"clang32","clang64"]]} | ||
25 | -- We can't actually use the git version from github, it's missing luac.c, which is needed to build the luac executable. | ||
26 | -- Even though early makefiles, and later `onelua.c` files suggest it should exist. | ||
2 | 27 | ||
3 | return { | 28 | local builds = {} |
4 | { | 29 | for version, link, name, optimization, rel, flag, _, image in cartesian(lua_versions, optimizations, debug, compilers) do |
5 | name = "lua51", | 30 | table.insert(builds,{ |
31 | image = "image-" .. compilers, | ||
32 | name = "lua" .. version .. optimization .. "-" .. rel .. "-" .. name .. "-" .. image, | ||
6 | requires = { | 33 | requires = { |
7 | {"git","lua#v5.1"}, | 34 | {"http", link}, |
8 | }, | 35 | }, |
9 | produces = {}, | 36 | produces = { |
10 | } | 37 | "lua.exe", |
11 | } | 38 | "lua" .. version .. ".dll", |
39 | "luac.exe", | ||
40 | }, | ||
41 | entrypoint = "init " .. rel .. " " .. flag, | ||
42 | }) | ||
43 | end | ||
44 | return builds | ||