diff --git a/anda/stardust/magnetar/anda.hcl b/anda/stardust/magnetar/anda.hcl new file mode 100644 index 0000000000..59f223d713 --- /dev/null +++ b/anda/stardust/magnetar/anda.hcl @@ -0,0 +1,8 @@ +project pkg { + rpm { + spec = "stardust-magnetar.spec" + } + labels { + nightly = 1 + } +} diff --git a/anda/stardust/magnetar/stardust-magnetar.spec b/anda/stardust/magnetar/stardust-magnetar.spec new file mode 100644 index 0000000000..bfb79000e8 --- /dev/null +++ b/anda/stardust/magnetar/stardust-magnetar.spec @@ -0,0 +1,41 @@ +%global commit 48064b84b71d27ceea00b5d2f19dcbf21d75f554 +%global commit_date 20240831 +%global shortcommit %(c=%{commit}; echo ${c:0:7}) +# Exclude input files from mangling +%global __brp_mangle_shebangs_exclude_from ^/usr/src/.*$ + +Name: stardust-magnetar +Version: %commit_date.%shortcommit +Release: 1%?dist +Summary: Workspaces client for Stardust XR. +URL: https://github.com/StardustXR/magnetar +Source0: %url/archive/%commit/magnetar-%commit.tar.gz +License: MIT +BuildRequires: cargo cmake anda-srpm-macros cargo-rpm-macros mold libudev-devel g++ libinput-devel libxkbcommon-x11-devel + +Provides: magnetar +Packager: Owen Zimmerman + +%description +%summary + +%prep +%autosetup -n magnetar-%commit +%cargo_prep_online + +%build + +%install +%define __cargo_common_opts %{?_smp_mflags} -Z avoid-dev-deps --locked +%cargo_install + + +%files +%_bindir/magnetar +%license LICENSE +%doc README.md + +%changelog +* Wed Sep 11 2024 Owen-sz +- Package StardustXR magnetar + diff --git a/anda/stardust/magnetar/update.rhai b/anda/stardust/magnetar/update.rhai new file mode 100644 index 0000000000..6bca40b722 --- /dev/null +++ b/anda/stardust/magnetar/update.rhai @@ -0,0 +1,5 @@ +rpm.global("commit", gh_commit("StardustXR/magnetar")); +if rpm.changed() { + rpm.release(); + rpm.global("commit_date", date()); +} \ No newline at end of file