forked from semios/ports
Compare commits
1
Commits
| Author | SHA256 | Date | |
|---|---|---|---|
|
|
7e4e1ece86 |
@@ -41,6 +41,16 @@ def autolink_share_pkgconfig():
|
|||||||
if i.is_file():
|
if i.is_file():
|
||||||
make.link(f"share/pkgconfig/{i.name}", "/share/pkgconfig/" + i.name)
|
make.link(f"share/pkgconfig/{i.name}", "/share/pkgconfig/" + i.name)
|
||||||
|
|
||||||
|
def autolink_services():
|
||||||
|
for i in common.treedir("share/services"):
|
||||||
|
if i.is_file() and os.access(i.path, os.F_OK):
|
||||||
|
make.link(f"share/services/{i.name}", "/share/services/" + i.name)
|
||||||
|
|
||||||
|
def autolink_milestones():
|
||||||
|
for i in common.treedir("share/milestones"):
|
||||||
|
if i.is_file() and os.access(i.path, os.F_OK):
|
||||||
|
make.link(f"share/milestones/{i.name}", "/share/milestones/" + i.name)
|
||||||
|
|
||||||
|
|
||||||
def autolink(composer: pkgcomposer.PkgComposer):
|
def autolink(composer: pkgcomposer.PkgComposer):
|
||||||
os.chdir(composer.workdir + "/bundle/")
|
os.chdir(composer.workdir + "/bundle/")
|
||||||
@@ -64,3 +74,13 @@ def autolink(composer: pkgcomposer.PkgComposer):
|
|||||||
autolink_share_pkgconfig()
|
autolink_share_pkgconfig()
|
||||||
except:
|
except:
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
try:
|
||||||
|
autolink_services()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|
||||||
|
try:
|
||||||
|
autolink_milestones()
|
||||||
|
except:
|
||||||
|
pass
|
||||||
|
|||||||
@@ -1,8 +1,8 @@
|
|||||||
{
|
{
|
||||||
"os_name": "\u001b[36;4mSemiOS\u001b[0m",
|
"os_name": "\u001b[36;4mSemiOS\u001b[0m",
|
||||||
"config_dir": "/var/config/airup",
|
"config_dir": "/var/config/airup",
|
||||||
"service_dir": "/share/airup/services",
|
"service_dir": "/share/services",
|
||||||
"milestone_dir": "/share/airup/milestones",
|
"milestone_dir": "/share/milestones",
|
||||||
"runtime_dir": "/run/airup",
|
"runtime_dir": "/run/airup",
|
||||||
"env_vars": {},
|
"env_vars": {},
|
||||||
"early_cmds": []
|
"early_cmds": []
|
||||||
|
|||||||
@@ -16,14 +16,30 @@ def build():
|
|||||||
shutil.copy2("../../build_manifest.json", "build_manifest.json")
|
shutil.copy2("../../build_manifest.json", "build_manifest.json")
|
||||||
rust.build()
|
rust.build()
|
||||||
|
|
||||||
|
|
||||||
on_build(build)
|
on_build(build)
|
||||||
|
|
||||||
|
|
||||||
|
def patch_logger_airs(path):
|
||||||
|
with open(path) as fd:
|
||||||
|
content = fd.read()
|
||||||
|
content = content.replace(
|
||||||
|
"/usr/libexec/airup/airup-fallback-logger",
|
||||||
|
get_prefix('airup') + "/libexec/airup-fallback-logger",
|
||||||
|
)
|
||||||
|
with open(path, 'wt+') as fd:
|
||||||
|
fd.write(content)
|
||||||
|
|
||||||
|
|
||||||
def pack_airup(composer):
|
def pack_airup(composer):
|
||||||
os.chdir(rust.artifacts_dir())
|
|
||||||
composer.makedir("bin")
|
composer.makedir("bin")
|
||||||
composer.makedir("libexec")
|
composer.makedir("libexec")
|
||||||
|
composer.makedirs("share/services")
|
||||||
|
|
||||||
|
patch_logger_airs("docs/resources/airup-fallback-logger.airs")
|
||||||
|
composer.addfile("docs/resources/airup-fallback-logger.airs", "share/services/airup-fallback-logger.airs")
|
||||||
|
composer.addfile("docs/resources/airupd.airs", "share/services/airupd.airs")
|
||||||
|
|
||||||
|
os.chdir(rust.artifacts_dir())
|
||||||
composer.addfile("airup", "bin/airup")
|
composer.addfile("airup", "bin/airup")
|
||||||
composer.addfile("airupd", "bin/airupd")
|
composer.addfile("airupd", "bin/airupd")
|
||||||
composer.addfile("airup-fallback-logger", "libexec/airup-fallback-logger")
|
composer.addfile("airup-fallback-logger", "libexec/airup-fallback-logger")
|
||||||
@@ -32,3 +48,4 @@ def pack_airup(composer):
|
|||||||
package("airup")
|
package("airup")
|
||||||
on_pack(pack_airup)
|
on_pack(pack_airup)
|
||||||
dep("semi-libc @same-arch")
|
dep("semi-libc @same-arch")
|
||||||
|
link("bin/airupd", "/bin/init")
|
||||||
|
|||||||
@@ -0,0 +1,26 @@
|
|||||||
|
import subprocess
|
||||||
|
import os
|
||||||
|
import lib
|
||||||
|
|
||||||
|
from lib.make import *
|
||||||
|
|
||||||
|
version("0.1.0-alpha.1")
|
||||||
|
description("SemiOS init scripts")
|
||||||
|
maintainer("sisungo <[email protected]>")
|
||||||
|
source_url("https://gitea.semilabs.org/semios/init-scripts/archive/0.1.0-alpha.1.tar.gz")
|
||||||
|
|
||||||
|
|
||||||
|
def build():
|
||||||
|
subprocess.run(["env", f"PREFIX={get_prefix('init-scripts')}", "sh", "install.sh"], check=True)
|
||||||
|
os.chdir("./target")
|
||||||
|
|
||||||
|
on_build(build)
|
||||||
|
|
||||||
|
|
||||||
|
def pack(composer):
|
||||||
|
composer.add("share")
|
||||||
|
composer.add("bin")
|
||||||
|
|
||||||
|
package("init-scripts")
|
||||||
|
arch_any()
|
||||||
|
on_pack(pack)
|
||||||
@@ -1,38 +0,0 @@
|
|||||||
from lib import cpp
|
|
||||||
from lib.make import *
|
|
||||||
|
|
||||||
version("1.13.7")
|
|
||||||
description("Wrapper library for evdev devices")
|
|
||||||
maintainer("sisungo <[email protected]>")
|
|
||||||
source_url("https://gitlab.freedesktop.org/libevdev/libevdev/-/archive/libevdev-1.13.7/libevdev-libevdev-1.13.7.tar.gz?ref_type=tags")
|
|
||||||
|
|
||||||
builddep("shortcut/c")
|
|
||||||
builddep("shortcut/meson")
|
|
||||||
builddep("linux-dev @target")
|
|
||||||
|
|
||||||
|
|
||||||
def build():
|
|
||||||
cpp.meson_setup([
|
|
||||||
"--prefix=/",
|
|
||||||
f"--libdir={get_prefix('libevdev')}/lib",
|
|
||||||
f"--includedir={get_prefix('libevdev-dev')}/include",
|
|
||||||
"-Dtests=disabled",
|
|
||||||
"-Ddocumentation=disabled",
|
|
||||||
])
|
|
||||||
cpp.meson_compile()
|
|
||||||
cpp.meson_install()
|
|
||||||
|
|
||||||
on_build(build)
|
|
||||||
|
|
||||||
|
|
||||||
package("libevdev")
|
|
||||||
dep("semi-libc @same-arch")
|
|
||||||
cpp.use_auto_pack(["lib"])
|
|
||||||
|
|
||||||
package("libevdev-tools")
|
|
||||||
dep("libevdev (same)")
|
|
||||||
cpp.use_auto_pack(["bin"])
|
|
||||||
|
|
||||||
package("libevdev-dev")
|
|
||||||
dep("libevdev (same)")
|
|
||||||
cpp.use_auto_pack(["dev"])
|
|
||||||
@@ -1,58 +0,0 @@
|
|||||||
import glob
|
|
||||||
|
|
||||||
from lib import cpp
|
|
||||||
from lib.make import *
|
|
||||||
|
|
||||||
version("1.30.4")
|
|
||||||
description("Input device management and event handling library")
|
|
||||||
maintainer("sisungo <[email protected]>")
|
|
||||||
source_url("https://gitlab.freedesktop.org/libinput/libinput/-/archive/1.30.4/libinput-1.30.4.tar.gz")
|
|
||||||
|
|
||||||
builddep("shortcut/c")
|
|
||||||
builddep("shortcut/meson")
|
|
||||||
builddep("lxdeviced-libudev-dev @target")
|
|
||||||
builddep("libevdev-dev @target")
|
|
||||||
builddep("libmtdev-dev @target")
|
|
||||||
builddep("libwacom-dev @target")
|
|
||||||
builddep("linux-dev @target")
|
|
||||||
|
|
||||||
|
|
||||||
def build():
|
|
||||||
cpp.meson_setup([
|
|
||||||
"--prefix=/",
|
|
||||||
f"--libdir={get_prefix('libinput')}/lib",
|
|
||||||
f"--libexecdir={get_prefix('libinput-tools')}/libexec",
|
|
||||||
f"--includedir={get_prefix('libinput-dev')}/include",
|
|
||||||
"--sysconfdir=/var/config",
|
|
||||||
f"--datadir={get_prefix('libinput')}/share",
|
|
||||||
"-Ddebug-gui=false",
|
|
||||||
"-Dtests=false",
|
|
||||||
])
|
|
||||||
cpp.meson_compile()
|
|
||||||
cpp.meson_install()
|
|
||||||
|
|
||||||
on_build(build)
|
|
||||||
|
|
||||||
|
|
||||||
def pack(composer):
|
|
||||||
composer.makedir("lib")
|
|
||||||
for i in glob.glob("lib/*so*"):
|
|
||||||
composer.add(i)
|
|
||||||
composer.makedir("share")
|
|
||||||
composer.add("share/libinput")
|
|
||||||
|
|
||||||
def pack_tools(composer):
|
|
||||||
composer.add("bin")
|
|
||||||
composer.add("libexec")
|
|
||||||
|
|
||||||
package("libinput")
|
|
||||||
dep("semi-libc @same-arch")
|
|
||||||
on_pack(pack)
|
|
||||||
|
|
||||||
package("libinput-tools")
|
|
||||||
dep("libinput (same)")
|
|
||||||
on_pack(pack_tools)
|
|
||||||
|
|
||||||
package("libinput-dev")
|
|
||||||
dep("libinput (same)")
|
|
||||||
cpp.use_auto_pack(["dev"])
|
|
||||||
@@ -1,32 +0,0 @@
|
|||||||
from lib import cpp
|
|
||||||
from lib.make import *
|
|
||||||
|
|
||||||
version("1.1.7")
|
|
||||||
description("a stand-alone library which transforms all variants of kernel MT events to the slotted type B protocol")
|
|
||||||
maintainer("sisungo <[email protected]>")
|
|
||||||
source_url("https://bitmath.se/org/code/mtdev/mtdev-1.1.7.tar.gz")
|
|
||||||
|
|
||||||
builddep("shortcut/c")
|
|
||||||
builddep("shortcut/autotools")
|
|
||||||
builddep("linux-dev @target")
|
|
||||||
|
|
||||||
|
|
||||||
def build():
|
|
||||||
cpp.configure([
|
|
||||||
"--prefix=/",
|
|
||||||
f"--libdir={get_prefix('libmtdev')}/lib",
|
|
||||||
f"--includedir={get_prefix('libmtdev-dev')}/include",
|
|
||||||
])
|
|
||||||
cpp.make()
|
|
||||||
cpp.make_install()
|
|
||||||
|
|
||||||
on_build(build)
|
|
||||||
|
|
||||||
|
|
||||||
package("libmtdev")
|
|
||||||
dep("semi-libc @same-arch")
|
|
||||||
cpp.use_auto_pack(["lib"])
|
|
||||||
|
|
||||||
package("libmtdev-dev")
|
|
||||||
dep("libmtdev (same)")
|
|
||||||
cpp.use_auto_pack(["dev"])
|
|
||||||
@@ -1,48 +0,0 @@
|
|||||||
from lib import cpp
|
|
||||||
from lib.make import *
|
|
||||||
|
|
||||||
version("2.19.1")
|
|
||||||
description("libwacom is a tablet description library")
|
|
||||||
maintainer("sisungo <[email protected]>")
|
|
||||||
source_url("https://github.com/linuxwacom/libwacom/releases/download/libwacom-2.19.1/libwacom-2.19.1.tar.xz")
|
|
||||||
|
|
||||||
builddep("shortcut/c")
|
|
||||||
builddep("shortcut/meson")
|
|
||||||
builddep("linux-dev @target")
|
|
||||||
builddep("libgudev-dev @target")
|
|
||||||
builddep("libevdev-dev @target")
|
|
||||||
|
|
||||||
|
|
||||||
def build():
|
|
||||||
cpp.meson_setup([
|
|
||||||
"--prefix=/",
|
|
||||||
f"--libdir={get_prefix('libwacom')}/lib",
|
|
||||||
f"--bindir={get_prefix('libwacom-tools')}/bin",
|
|
||||||
f"--includedir={get_prefix('libwacom-dev')}/include",
|
|
||||||
f"--datadir={get_prefix('libwacom')}/share",
|
|
||||||
"-Dtests=disabled",
|
|
||||||
])
|
|
||||||
cpp.meson_compile()
|
|
||||||
cpp.meson_install()
|
|
||||||
|
|
||||||
on_build(build)
|
|
||||||
|
|
||||||
|
|
||||||
package("libwacom")
|
|
||||||
dep("semi-libc @same-arch")
|
|
||||||
dep("libgudev @same-arch")
|
|
||||||
dep("libgobject @same-arch")
|
|
||||||
dep("libglib @same-arch")
|
|
||||||
dep("libevdev @same-arch")
|
|
||||||
cpp.use_auto_pack(["lib"])
|
|
||||||
|
|
||||||
package("libwacom-tools")
|
|
||||||
dep("libwacom (same)")
|
|
||||||
cpp.use_auto_pack(["bin"])
|
|
||||||
|
|
||||||
package("libwacom-dev")
|
|
||||||
dep("libwacom (same)")
|
|
||||||
dep("libgudev-dev @same-arch")
|
|
||||||
dep("glib-dev @same-arch")
|
|
||||||
dep("libevdev-dev @same-arch")
|
|
||||||
cpp.use_auto_pack(["dev"])
|
|
||||||
@@ -35,6 +35,7 @@ Libs: -L${libdir} -ludev
|
|||||||
def pack(composer):
|
def pack(composer):
|
||||||
composer.makedirs("share/device")
|
composer.makedirs("share/device")
|
||||||
composer.add_dir("misc/rules", "share/device/rules")
|
composer.add_dir("misc/rules", "share/device/rules")
|
||||||
|
composer.add_dir("misc/airup", "share/services")
|
||||||
oldpwd = os.getcwd()
|
oldpwd = os.getcwd()
|
||||||
os.chdir(rust.artifacts_dir())
|
os.chdir(rust.artifacts_dir())
|
||||||
composer.makedir("bin")
|
composer.makedir("bin")
|
||||||
|
|||||||
Reference in New Issue
Block a user