Merge pull request #218182 from ilyakooo0/iko/init-click

ubports-click: init at 22-02-2023
This commit is contained in:
Nick Cao 2023-03-01 18:05:03 +08:00 committed by GitHub
commit eb201d6d8a
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 111 additions and 0 deletions

View file

@ -0,0 +1,23 @@
diff --git a/click_package/Makefile.am b/click_package/Makefile.am
index 4981d74..9df9e79 100644
--- a/click_package/Makefile.am
+++ b/click_package/Makefile.am
@@ -1,5 +1,3 @@
-SUBDIRS = tests
-
noinst_SCRIPTS = paths.py
CLEANFILES = $(noinst_SCRIPTS)
diff --git a/configure.ac b/configure.ac
index 8f4dc9e..adbd366 100644
--- a/configure.ac
+++ b/configure.ac
@@ -52,8 +52,6 @@ PKG_CHECK_MODULES([SERVICE], [
AC_SUBST([SERVICE_CFLAGS])
AC_SUBST([SERVICE_LIBS])
-AC_CHECK_PROG(DBUS_TEST_RUNNER_CHECK,dbus-test-runner,yes)
-AS_IF([test "${DBUS_TEST_RUNNER_CHECK}" != "yes"], [AC_MSG_ERROR([dbus-test-runner not found])])
AC_CHECK_PROG(GDBUS_CHECK,gdbus,yes)
AS_IF([test "${GDBUS_CHECK}" != "yes"], [AC_MSG_ERROR([gdbus (glib) not found])])

View file

@ -0,0 +1,86 @@
{ lib
, fetchFromGitLab
, buildPythonApplication
, autoreconfHook
, debian
, perl
, vala
, pkg-config
, libgee
, json-glib
, properties-cpp
, gobject-introspection
, getopt
, setuptools
, pygobject3
, wrapGAppsHook
}:
buildPythonApplication {
pname = "click";
version = "unstable-2023-02-22";
format = "other";
src = fetchFromGitLab {
owner = "ubports";
repo = "development/core/click";
rev = "aaf2735e8e6cbeaf2e429c70136733513a81718a";
sha256 = "sha256-pNu995/w3tbz15QQVdVYBnWnAoZmqWj1DN/5PZZ0iZw=";
};
configureFlags = [
"--with-systemdsystemunitdir=${placeholder "out"}/lib/systemd/system"
"--with-systemduserunitdir=${placeholder "out"}/lib/systemd/user"
];
preFixup = ''
makeWrapperArgs+=(
--prefix LD_LIBRARY_PATH : "$out/lib"
)
'';
preConfigure = ''
export click_cv_perl_vendorlib=$out/${perl.libPrefix}
export PYTHON_INSTALL_FLAGS="--prefix=$out"
'';
nativeBuildInputs = [
autoreconfHook
perl
pkg-config
gobject-introspection
vala
getopt
wrapGAppsHook
];
# Tests were omitted for time constraint reasons
doCheck = false;
enableParallelBuilding = true;
patches = [
# dbus-test-runner not packaged yet, otherwise build-time dependency even when not running tests
./dbus-test-runner.patch
];
buildInputs = [
libgee
json-glib
properties-cpp
];
propagatedBuildInputs = [
debian
pygobject3
setuptools
];
meta = {
description = "A tool to build click packages. Mainly used for Ubuntu Touch.";
homepage = "https://gitlab.com/ubports/development/core/click";
license = lib.licenses.gpl3Only;
maintainers = with lib.maintainers; [ ilyakooo0 OPNA2608 ];
platforms = lib.platforms.linux;
};
}

View file

@ -16207,6 +16207,8 @@ with pkgs;
bupc = callPackage ../development/compilers/bupc { }; bupc = callPackage ../development/compilers/bupc { };
ubports-click = python3Packages.callPackage ../development/tools/click { };
uasm = callPackage ../development/compilers/uasm { }; uasm = callPackage ../development/compilers/uasm { };
urn = callPackage ../development/compilers/urn { }; urn = callPackage ../development/compilers/urn { };