diff --git a/anda/lib/astal/ags/ags.spec b/anda/lib/astal/ags/ags.spec new file mode 100644 index 0000000000..33dd2d9e69 --- /dev/null +++ b/anda/lib/astal/ags/ags.spec @@ -0,0 +1,84 @@ +# Generated by go2rpm 1.15.0 +%bcond check 0 +%bcond bootstrap 0 + +%if %{with bootstrap} +%global debug_package %{nil} +%endif + +%if %{with bootstrap} +%global __requires_exclude %{?__requires_exclude:%{__requires_exclude}|}^golang\\(.*\\)$ +%endif + +# https://github.com/Aylur/ags +%global goipath github.com/Aylur/ags +Version: 2.3.0 + +%gometa -f + +%global common_description %{expand: +Scaffolding CLI for Astal+TypeScript.} + +%global golicenses LICENSE +%global godocs docs README.md + +Name: ags +Release: %autorelease +Summary: Scaffolding CLI for Astal+TypeScript + +License: GPL-3.0-only +URL: %{gourl} +Source: %{gosource} +Provides: golang-github-aylur-ags = %version-%release +Packager: madonuko + +BuildRequires: anda-srpm-macros +%description %{common_description} + +%gopkg + +%prep +%goprep # -A +#autopatch -p1 +%go_prep_online + +%build +%dnl for cmd in cmd/* ; do +%dnl go build -buildmode pie -compiler gc -tags="rpm_crashtraceback ${GO_BUILDTAGS-${BUILDTAGS-}}" -a -x \ +%dnl -ldflags "-X main.version=%{version} \ +%dnl -B 0x$(echo "%{name}-%{version}-%{release}-${SOURCE_DATE_EPOCH:-}" | sha1sum | cut -d ' ' -f1) \ +%dnl -compressdwarf=false -linkmode=external \ +%dnl -extldflags '-Wl,-z,relro -Wl,--as-needed -Wl,-z,pack-relative-relocs -Wl,-z,now \ +%dnl -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 \ +%dnl -Wl,--build-id=sha1'" \ +%dnl -o %{gobuilddir}/bin/$(basename $cmd) $cmd +%dnl done +go build -buildmode pie -compiler gc -tags="rpm_crashtraceback ${GO_BUILDTAGS-${BUILDTAGS-}}" -a -x \ + -ldflags "-X main.version=%{version} \ + -B 0x$(echo "%{name}-%{version}-%{release}-${SOURCE_DATE_EPOCH:-}" | sha1sum | cut -d ' ' -f1) \ + -compressdwarf=false -linkmode=external \ + -extldflags '-Wl,-z,relro -Wl,--as-needed -Wl,-z,pack-relative-relocs -Wl,-z,now \ + -specs=/usr/lib/rpm/redhat/redhat-hardened-ld -specs=/usr/lib/rpm/redhat/redhat-annobin-cc1 \ + -Wl,--build-id=sha1'" \ + -o %{gobuilddir}/bin/ags . + +%install +install -m 0755 -vd %{buildroot}%{_bindir} +install -m 0755 -vp %{gobuilddir}/bin/* %{buildroot}%{_bindir}/ + +%if %{without bootstrap} +%if %{with check} +%check +%gocheck +%endif +%endif + +%if %{without bootstrap} +%files +%license LICENSE +%doc docs README.md +%{_bindir}/ags +%endif + +%changelog +%autochangelog diff --git a/anda/lib/astal/ags/anda.hcl b/anda/lib/astal/ags/anda.hcl new file mode 100644 index 0000000000..036bed8deb --- /dev/null +++ b/anda/lib/astal/ags/anda.hcl @@ -0,0 +1,5 @@ +project pkg { + rpm { + spec = "ags.spec" + } +} diff --git a/anda/lib/astal/ags/update.rhai b/anda/lib/astal/ags/update.rhai new file mode 100644 index 0000000000..a520ca2506 --- /dev/null +++ b/anda/lib/astal/ags/update.rhai @@ -0,0 +1 @@ +rpm.version(gh("Aylur/ags"));