From d20a80ffda9bb2d2f82dece4192c6ed5a721ecfa Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 18:12:33 +0530 Subject: [PATCH 1/7] Add: .spec File For RPM and SUSE Distros --- azin.spec | 77 +++++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 77 insertions(+) create mode 100644 azin.spec diff --git a/azin.spec b/azin.spec new file mode 100644 index 0000000..b7d308b --- /dev/null +++ b/azin.spec @@ -0,0 +1,77 @@ +# +# spec file for package azin +# +# Copyright (c) 2026 Azin Contributors +# +# All modifications and additions to the file contributed by third parties +# remain the property of their respective owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (MIT). +# + +Name: azin +Version: 0.2.2 +Release: 1%{?dist} +Summary: A modern, high-performance systems programming language compiler +License: MIT +Group: Development/Languages/Other +URL: https://azin-lang.org +Source0: %{name}-%{version}.tar.gz +# Source1 generated via OBS `obs-service-go_modules` or `go mod vendor` +Source1: vendor.tar.gz + +# Supported architectures for Go compiler (ARM 64-bit aarch64, ARM 32-bit arm, x86_64, etc.) +%if 0%{?fedora} || 0%{?rhel} +ExclusiveArch: %{go_arches} +%else +ExclusiveArch: aarch64 %{arm} x86_64 ppc64le s390x riscv64 +%endif + +BuildRequires: golang >= 1.22 + +# Azin compiles source code by transpiling to C11 and invoking a native C compiler. +# GCC or Clang is required at runtime to generate native binaries. +Requires: gcc +Recommends: clang +Recommends: glibc-devel + +%description +Azin is a modern, high-performance systems programming language engineered for +structural clarity, low-level execution control, and human readability. + +Key features: +- Explicit block scoping: Replaces traditional brace nesting ({}) with clean do / end blocks. +- Static typing: Compiler-enforced type safety with no runtime type checks or garbage collection. +- Minimalist punctuation: Eliminates unnecessary syntax where program structure is explicit. +- Systems-first: Designed for direct native compilation via C11 transpilation. + +%prep +%autosetup -n %{name}-%{version} -a 1 + +%build +# Disable cgo for static compiler binary, set trimpath for reproducible builds +export CGO_ENABLED=0 +export GOFLAGS="-buildmode=pie -trimpath -mod=vendor" + +go build \ + -ldflags="-s -w -X main.Version=%{version}" \ + -o bin/azc \ + ./cmd/azc + +%install +install -D -m 0755 bin/azc %{buildroot}%{_bindir}/azc + +%check +# Run internal unit tests during build +export CGO_ENABLED=0 +export GOFLAGS="-mod=vendor" +go test ./... + +%files +%license LICENSE +%doc README.md VERSIONING.md +%{_bindir}/azc + +%changelog +* Fri Jul 31 2026 Azin Packaging Team - 0.2.2-1 +- Initial RPM package spec for Open Build Service (OBS) with ARM (aarch64/armv7hl) support From d287d38491fe81d94d8d718a05c07be37fb34081 Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 18:16:34 +0530 Subject: [PATCH 2/7] Bug Fix: .spec File For RPM and SUSE Distros --- azin.spec | 10 +++------- 1 file changed, 3 insertions(+), 7 deletions(-) diff --git a/azin.spec b/azin.spec index b7d308b..f4107cf 100644 --- a/azin.spec +++ b/azin.spec @@ -20,12 +20,8 @@ Source0: %{name}-%{version}.tar.gz # Source1 generated via OBS `obs-service-go_modules` or `go mod vendor` Source1: vendor.tar.gz -# Supported architectures for Go compiler (ARM 64-bit aarch64, ARM 32-bit arm, x86_64, etc.) -%if 0%{?fedora} || 0%{?rhel} -ExclusiveArch: %{go_arches} -%else -ExclusiveArch: aarch64 %{arm} x86_64 ppc64le s390x riscv64 -%endif +# Explicitly list architectures to prevent OBS unexpanded macro exclusion +ExclusiveArch: x86_64 aarch64 %{arm} ppc64le s390x riscv64 BuildRequires: golang >= 1.22 @@ -74,4 +70,4 @@ go test ./... %changelog * Fri Jul 31 2026 Azin Packaging Team - 0.2.2-1 -- Initial RPM package spec for Open Build Service (OBS) with ARM (aarch64/armv7hl) support +- Fix ExclusiveArch macro expansion issue on OBS for Fedora/RHEL targets From 05c3fc976c7fb02e60b5dca5e4257e2b32044427 Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 18:21:26 +0530 Subject: [PATCH 3/7] Bug Fix: .spec File For RPM and SUSE Distros 2 --- azin.spec | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/azin.spec b/azin.spec index f4107cf..4d0e336 100644 --- a/azin.spec +++ b/azin.spec @@ -17,19 +17,13 @@ License: MIT Group: Development/Languages/Other URL: https://azin-lang.org Source0: %{name}-%{version}.tar.gz -# Source1 generated via OBS `obs-service-go_modules` or `go mod vendor` Source1: vendor.tar.gz -# Explicitly list architectures to prevent OBS unexpanded macro exclusion -ExclusiveArch: x86_64 aarch64 %{arm} ppc64le s390x riscv64 - BuildRequires: golang >= 1.22 # Azin compiles source code by transpiling to C11 and invoking a native C compiler. -# GCC or Clang is required at runtime to generate native binaries. Requires: gcc Recommends: clang -Recommends: glibc-devel %description Azin is a modern, high-performance systems programming language engineered for @@ -45,7 +39,6 @@ Key features: %autosetup -n %{name}-%{version} -a 1 %build -# Disable cgo for static compiler binary, set trimpath for reproducible builds export CGO_ENABLED=0 export GOFLAGS="-buildmode=pie -trimpath -mod=vendor" @@ -58,7 +51,6 @@ go build \ install -D -m 0755 bin/azc %{buildroot}%{_bindir}/azc %check -# Run internal unit tests during build export CGO_ENABLED=0 export GOFLAGS="-mod=vendor" go test ./... @@ -70,4 +62,4 @@ go test ./... %changelog * Fri Jul 31 2026 Azin Packaging Team - 0.2.2-1 -- Fix ExclusiveArch macro expansion issue on OBS for Fedora/RHEL targets +- Initial RPM package spec for Open Build Service (OBS) From 7456c33966b3be89c6543e41315083d72e887d04 Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 18:56:10 +0530 Subject: [PATCH 4/7] Bug Fix: .spec File For RPM and SUSE Distros 3 --- azin.spec | 44 +++++++++----------------------------------- 1 file changed, 9 insertions(+), 35 deletions(-) diff --git a/azin.spec b/azin.spec index 4d0e336..7c403d2 100644 --- a/azin.spec +++ b/azin.spec @@ -1,58 +1,32 @@ -# -# spec file for package azin -# -# Copyright (c) 2026 Azin Contributors -# -# All modifications and additions to the file contributed by third parties -# remain the property of their respective owners, unless otherwise agreed -# upon. The license for this file, and modifications and additions to the -# file, is the same license as for the pristine package itself (MIT). -# - Name: azin Version: 0.2.2 Release: 1%{?dist} Summary: A modern, high-performance systems programming language compiler + License: MIT -Group: Development/Languages/Other -URL: https://azin-lang.org -Source0: %{name}-%{version}.tar.gz -Source1: vendor.tar.gz +URL: https://azin-lang.org/ -BuildRequires: golang >= 1.22 +Source0: https://github.com/azin-lang/Azin/archive/refs/tags/v%{version}.tar.gz -# Azin compiles source code by transpiling to C11 and invoking a native C compiler. +BuildRequires: golang >= 1.22 Requires: gcc Recommends: clang %description -Azin is a modern, high-performance systems programming language engineered for -structural clarity, low-level execution control, and human readability. - -Key features: -- Explicit block scoping: Replaces traditional brace nesting ({}) with clean do / end blocks. -- Static typing: Compiler-enforced type safety with no runtime type checks or garbage collection. -- Minimalist punctuation: Eliminates unnecessary syntax where program structure is explicit. -- Systems-first: Designed for direct native compilation via C11 transpilation. +Azin is a modern, high-performance systems programming language compiler engineered for structural clarity, low-level execution control, and human readability. %prep -%autosetup -n %{name}-%{version} -a 1 +%autosetup -n Azin-%{version} %build export CGO_ENABLED=0 -export GOFLAGS="-buildmode=pie -trimpath -mod=vendor" - -go build \ - -ldflags="-s -w -X main.Version=%{version}" \ - -o bin/azc \ - ./cmd/azc +go build -trimpath -ldflags="-s -w -X main.Version=%{version}" -o bin/azc ./cmd/azc %install install -D -m 0755 bin/azc %{buildroot}%{_bindir}/azc %check export CGO_ENABLED=0 -export GOFLAGS="-mod=vendor" go test ./... %files @@ -61,5 +35,5 @@ go test ./... %{_bindir}/azc %changelog -* Fri Jul 31 2026 Azin Packaging Team - 0.2.2-1 -- Initial RPM package spec for Open Build Service (OBS) +* Fri Jul 31 2026 Azin Contributors - 0.2.2-1 +- Initial release for Copr From 7225b4850e01ba16124fe8f47a05072d806c915e Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 19:02:50 +0530 Subject: [PATCH 5/7] Bug Fix: .spec File For RPM and SUSE Distros 4 --- azin.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/azin.spec b/azin.spec index 7c403d2..2344494 100644 --- a/azin.spec +++ b/azin.spec @@ -27,6 +27,7 @@ install -D -m 0755 bin/azc %{buildroot}%{_bindir}/azc %check export CGO_ENABLED=0 +export AZC=$(pwd)/bin/azc go test ./... %files From d606a063dba93eabd3e03eae18e375ccbb570e29 Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 19:08:14 +0530 Subject: [PATCH 6/7] Bug Fix: Disable Debug Package Generation For Go Binary (COPR) --- azin.spec | 2 ++ 1 file changed, 2 insertions(+) diff --git a/azin.spec b/azin.spec index 2344494..7a69d2f 100644 --- a/azin.spec +++ b/azin.spec @@ -1,3 +1,5 @@ +%global debug_package %{nil} + Name: azin Version: 0.2.2 Release: 1%{?dist} From a649ce7c3ba8950fd03958d8831fa1bd140bc6f2 Mon Sep 17 00:00:00 2001 From: Zapaxe Date: Fri, 31 Jul 2026 19:21:37 +0530 Subject: [PATCH 7/7] Bug Fix: Azure Linux Fix (COPR) --- azin.spec | 1 + 1 file changed, 1 insertion(+) diff --git a/azin.spec b/azin.spec index 7a69d2f..b334e76 100644 --- a/azin.spec +++ b/azin.spec @@ -11,6 +11,7 @@ URL: https://azin-lang.org/ Source0: https://github.com/azin-lang/Azin/archive/refs/tags/v%{version}.tar.gz BuildRequires: golang >= 1.22 +BuildRequires: ca-certificates Requires: gcc Recommends: clang