forked from semios/ports
feat: add gtk & dependencies
Signed-off-by: sisungo <[email protected]>
This commit is contained in:
@@ -0,0 +1,63 @@
|
||||
import os
|
||||
import shutil
|
||||
|
||||
from lib.make import *
|
||||
from lib import cpp, python, arch
|
||||
|
||||
|
||||
upstream_version = "1.1.45"
|
||||
|
||||
version(upstream_version)
|
||||
description("an XSLT processor based on libxml2")
|
||||
maintainer("sisungo <[email protected]>")
|
||||
source_url("https://download.gnome.org/sources/libxslt/1.1/libxslt-1.1.45.tar.xz")
|
||||
|
||||
builddep("shortcut/c")
|
||||
builddep("shortcut/autotools")
|
||||
builddep("pkgconf @target")
|
||||
builddep("libxml2-dev @target")
|
||||
builddep("libpython-dev @target")
|
||||
builddep("libexpat")
|
||||
|
||||
|
||||
def build():
|
||||
cpp.configure([
|
||||
"--prefix=/",
|
||||
f"--libdir={get_prefix('libxslt')}/lib",
|
||||
f"--bindir={get_prefix('libxslt-tools')}/bin",
|
||||
f"--includedir={get_prefix('libxslt-dev')}/include",
|
||||
"--without-debug",
|
||||
])
|
||||
cpp.make()
|
||||
if os.path.exists("../cpp_install"):
|
||||
shutil.rmtree("../cpp_install")
|
||||
cpp.make_install()
|
||||
os.mkdir("py")
|
||||
os.rename(f"lib/{arch.get_target()}/python{python.PY3_VERSION}", "py/arch")
|
||||
os.rename(f"lib/python{python.PY3_VERSION}", "py/nonarch")
|
||||
|
||||
on_build(build)
|
||||
|
||||
|
||||
package("libxslt")
|
||||
dep("libxml2 @same-arch")
|
||||
cpp.use_auto_pack(["lib"])
|
||||
|
||||
package("libxslt-tools")
|
||||
dep("libxslt (same)")
|
||||
cpp.use_auto_pack(["bin"])
|
||||
|
||||
package("libxslt-dev")
|
||||
dep("libxslt (same)")
|
||||
dep("libxml2-dev @same-arch")
|
||||
cpp.use_auto_pack(["dev"])
|
||||
|
||||
def pack_py(composer):
|
||||
composer.makedir("lib")
|
||||
composer.add_dir("py/arch", f"lib/python{python.PY3_VERSION}", merge=True)
|
||||
composer.add_dir("py/nonarch", f"lib/python{python.PY3_VERSION}", merge=True)
|
||||
|
||||
package("libxslt.py")
|
||||
python.version(upstream_version)
|
||||
dep(f"libxslt (={upstream_version}) @same-arch")
|
||||
on_pack(pack_py)
|
||||
Reference in New Issue
Block a user