Skip to content

Commit

Permalink
add: stardust-flatland (#2049) (#2098)
Browse files Browse the repository at this point in the history
* initial package for stardust-flatland

* move to stardust folder

* RPM bug workaround stardust-flatland.spec

Signed-off-by: Owen Zimmerman <[email protected]>

* Update stardust-flatland.spec

Signed-off-by: Owen Zimmerman <[email protected]>

* Update anda/stardust/flatland/stardust-flatland.spec

Co-authored-by: madomado <[email protected]>
Signed-off-by: Owen Zimmerman <[email protected]>

* Update anda/stardust/flatland/stardust-flatland.spec

Co-authored-by: madomado <[email protected]>
Signed-off-by: Owen Zimmerman <[email protected]>

* Update anda/stardust/flatland/stardust-flatland.spec

Co-authored-by: madomado <[email protected]>
Signed-off-by: Owen Zimmerman <[email protected]>

* Test fix stardust-flatland.spec

Testing CI build without

'Requires:       libgcc glibc'

Signed-off-by: Owen Zimmerman <[email protected]>

* Update stardust-flatland.spec

Add packager

Signed-off-by: Owen Zimmerman <[email protected]>

* Update update.rhai

Remove if statement from Rhai

Signed-off-by: Owen Zimmerman <[email protected]>

* Update anda.hcl

Fix indentation

Signed-off-by: Owen Zimmerman <[email protected]>

* Update anda/stardust/flatland/update.rhai

Co-authored-by: madomado <[email protected]>
Signed-off-by: Owen Zimmerman <[email protected]>

* Update stardust-flatland.spec

Lock cargo install

Signed-off-by: Owen Zimmerman <[email protected]>

* Update stardust-flatland.spec

Unify summaries

Signed-off-by: Owen Zimmerman <[email protected]>

* Update stardust-flatland.spec

add environment variable before cargo build

Signed-off-by: Owen Zimmerman <[email protected]>

---------

Signed-off-by: Owen Zimmerman <[email protected]>
Co-authored-by: june-fish <[email protected]>
Co-authored-by: madomado <[email protected]>
(cherry picked from commit ad0f734)

Co-authored-by: Owen Zimmerman <[email protected]>
  • Loading branch information
raboneko and Owen-sz authored Sep 19, 2024
1 parent 6bc41fa commit 16cd08b
Show file tree
Hide file tree
Showing 3 changed files with 54 additions and 0 deletions.
8 changes: 8 additions & 0 deletions anda/stardust/flatland/anda.hcl
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
project pkg {
rpm {
spec = "stardust-flatland.spec"
}
labels {
nightly = 1
}
}
41 changes: 41 additions & 0 deletions anda/stardust/flatland/stardust-flatland.spec
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
%global commit b83f2eced868fe71248ba7681df978698eb978f0
%global commit_date 20240824
%global shortcommit %(c=%{commit}; echo ${c:0:7})
# Exclude input files from mangling
%global __brp_mangle_shebangs_exclude_from ^/usr/src/.*$

Name: stardust-flatland
Version: %commit_date.%shortcommit
Release: 1%?dist
Summary: Flatland for Stardust XR.
URL: https://github.com/StardustXR/flatland
Source0: %url/archive/%commit/flatland-%commit.tar.gz
License: MIT
BuildRequires: cargo cmake anda-srpm-macros cargo-rpm-macros mold

Provides: flatland
Packager: Owen Zimmerman <[email protected]>

%description
%summary

%prep
%autosetup -n flatland-%commit
%cargo_prep_online

%build
STARDUST_RES_PREFIXES=/usr/share

%install
%define __cargo_common_opts %{?_smp_mflags} -Z avoid-dev-deps --locked
STARDUST_RES_PREFIXES=%_datadir
%cargo_install

%files
%_bindir/flatland
%license LICENSE
%doc README.md

%changelog
* Sat Sep 7 2024 Owen-sz <[email protected]>
- Package StardustXR Flatland
5 changes: 5 additions & 0 deletions anda/stardust/flatland/update.rhai
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
rpm.global("commit", gh_commit("StardustXR/flatland"));
if rpm.changed() {
rpm.release();
rpm.global("commit_date", date());
}

0 comments on commit 16cd08b

Please sign in to comment.