A curated collection of performance-optimized PKGBUILDs for Arch Linux packages with custom patches, aggressive compiler optimizations, and enhanced configurations.
- ISA Level Detection - Check x86-64 microarchitecture level support (based on CachyOS/cachyos-repo-add-script)
This repository provides optimized package builds for Arch Linux with a focus on:
- Performance: Aggressive compiler optimizations (-O3, LTO, PGO, native architecture targeting)
- Security: Enhanced security flags, verified checksums, HTTPS sources
- Customization: Custom patches, debloating, and performance tuning
- Quality: Automated CI/CD testing, comprehensive linting, and validation
- ✅ Automated builds with GitHub Actions CI/CD
- ✅ Docker support for complex packages (Firefox, OBS Studio, etc.)
- ✅ Parallel compilation with intelligent core limiting
- ✅ Caching support (sccache, ccache, apt packages)
- ✅ Multiple compiler support (Clang/LLVM preferred)
- ✅ Comprehensive linting (shellcheck, shellharden, shfmt, namcap)
- ✅ Automated formatting with consistent style enforcement
- ✅ EditorConfig integration for consistent coding standards
- ✅ Git hooks with lefthook for automated quality checks
- ✅ Profile-Guided Optimization (PGO) for critical packages
- ✅ Link-Time Optimization (LTO) enabled by default
- ✅ Native architecture targeting (march=native, mtune=native)
- ✅ Aggressive inlining and vectorization
- ✅ Memory layout optimizations (-fno-plt, section garbage collection)
# Install base development tools (Arch Linux)
sudo pacman -S base-devel git
# Optional but recommended
sudo pacman -S shellcheck shfmt docker sccache clang# Clone the repository
git clone https://github.com/Ven0m0/PKG.git
cd PKG
# Build a specific package
cd firefox
makepkg -si
# Or use the build script
cd ..
./build.sh firefox aria2 obs-studio# Automatically handled for Firefox, OBS Studio, etc.
./build.sh firefoxPKG/
├── .github/
│ ├── workflows/ # CI/CD pipelines (build, lint, automerge)
│ ├── instructions/ # GitHub-specific guidelines
│ └── agents/ # AI agent configurations
├── <package-name>/ # Individual package directories
│ ├── PKGBUILD # Package build script (required)
│ ├── .SRCINFO # Metadata (auto-generated)
│ ├── README.md # Package documentation
│ ├── patches/ # Custom patches
│ └── *.patch # Individual patch files
├── build.sh # Universal build script
├── lint.sh # Linting and validation
├── CLAUDE.md # AI assistant documentation
├── CONTRIBUTING.md # Contribution guidelines
├── SECURITY.md # Security policy
└── README.md # This file
| Package | Description | Optimizations |
|---|---|---|
| firefox | Web browser | PGO, BOLT, VA-API, aggressive optimizations |
| chromium | Web browser | Custom flags, performance patches |
| obs-studio | Video recording/streaming | Optimized build configuration |
| ffmpeg | Multimedia framework | Hardware acceleration, codec optimizations |
| mesa-git | Graphics drivers | Latest features, performance patches |
| wine-tkg-git | Windows compatibility | Custom patches, optimizations |
| llvm | Compiler infrastructure | Optimized build |
- aria2 - Download utility with speed optimizations
- curl - HTTP client with custom patches
- 7zip - Compression utility
- smartdns-rs - DNS resolver
- preload-ng - Application preloader
- dolphin-emu - GameCube/Wii emulator
- prismlauncher - Minecraft launcher
- heroic-games-launcher - Epic Games launcher
- dxvk variants - DirectX to Vulkan translation
- gitoxide - Rust-based Git tools
- vscode - Code editor with patches
- legcord/discord - Communication tools
See individual package directories for detailed documentation.
cd <package-name>
makepkg -si# Clean build (removes previous build artifacts)
makepkg -srC
# Skip dependency checks (for experienced users)
makepkg -si --nodeps
# Package only (no install)
makepkg -s# Build specific packages
./build.sh firefox chromium obs-studio
# Build all packages (not recommended)
./build.sh
# Force clean builds
./build.sh --clean firefoxThis repository uses lefthook for automated code quality checks.
# Install lefthook
# Linux/macOS via script
curl -1sLf 'https://dl.cloudsmith.io/public/evilmartians/lefthook/setup.deb.sh' | sudo -E bash
sudo apt-get install lefthook
# Or via Go
go install github.com/evilmartians/lefthook@latest
# Or via Homebrew (macOS)
brew install lefthook
# Or via uv (recommended for Python tools)
uv tool install lefthook
# Install hooks in repository
lefthook install
# Run hooks manually
lefthook run pre-commit
# Skip hooks temporarily
LEFTHOOK=0 git commit -m "message"# Run all linters
./lint.sh
# Lint specific package
cd <package>
shellcheck -x -a -s bash PKGBUILD
namcap PKGBUILD
shfmt -ln bash -bn -s -i 2 -w PKGBUILD- Create package directory:
mkdir new-package && cd new-package - Create
PKGBUILDfollowing PKGBUILD Guidelines - Generate metadata:
makepkg --printsrcinfo > .SRCINFO - Add documentation: Create
readme.mdusing the template - Test build:
makepkg -sr - Commit:
git add . && git commit -m "Add new-package: description"
See CONTRIBUTING.md for detailed guidelines.
- Edit
PKGBUILD(updatepkgverorpkgrel) - Update checksums:
updpkgsums - Regenerate metadata:
makepkg --printsrcinfo > .SRCINFO - Test:
makepkg -srC - Lint:
cd .. && ./lint.sh - Commit with descriptive message
- build.yml - Automated package building with matrix strategy
- lint.yml - Code quality checks (shellcheck, namcap, prettier, MegaLinter)
- automerge-dependabot.yml - Automated dependency updates
- APT packages cached for faster CI runs
- Docker layer caching enabled
- sccache for Rust compilation
- ccache for C/C++ compilation
Packages are detected automatically and built in parallel across multiple jobs.
Standard optimization flags used across packages:
# C/C++ compiler flags
export CFLAGS="${CFLAGS/-O2/-O3} -pipe -fno-plt -fstack-protector-strong"
export CXXFLAGS="${CXXFLAGS/-O2/-O3} -pipe -fno-plt -fstack-protector-strong"
# Linker flags
export LDFLAGS="-Wl,-O1,--sort-common,--as-needed,-z,relro,-z,now"
# Parallel compilation
export MAKEFLAGS="-j$(nproc)"Package-specific optimizations may include PGO, BOLT, Polly, and architecture-specific tuning.
Contributions are welcome! Please read CONTRIBUTING.md for:
- Code of conduct
- Development workflow
- Coding standards
- Pull request process
- Package submission guidelines
Security is a priority. See SECURITY.md for:
- Reporting vulnerabilities
- Security best practices
- Supported versions
- CachyOS-PKGBUILDS - High-performance Arch repository
- CachyOS Packages - Binary repository
- lseman's PKGBUILDs - PGO-optimized packages
- KISS-repo - Keep it simple packages
- Pika OS - Gaming-focused distribution
- Cloudflare quiche-mallard - QUIC protocol
- Cloudflare jpegtran - JPEG optimization
- Cloudflare BoringSSL - Post-quantum TLS
- Cloudflare reqwest - HTTP client
- patchutils - Patch manipulation
- mpatch - Rust patch utility
- shellcheck - Shell script linting
- shfmt - Shell formatter
- namcap - PKGBUILD linter
- CLAUDE.md - Comprehensive AI assistant guide and project conventions
- CONTRIBUTING.md - Contribution guidelines and workflow
- SECURITY.md - Security policy and vulnerability reporting
- TODO.md - Planned features and improvements
- Package READMEs - Individual package documentation in
<package>/readme.md
This repository contains PKGBUILDs and scripts under various licenses:
- Build scripts: MIT License (unless otherwise specified)
- PKGBUILDs: Follow upstream package licenses
- Patches: Typically inherit upstream license
See individual package directories for specific license information.
- Issues: GitHub Issues
- Discussions: Use GitHub Discussions for questions
- Pull Requests: Contributions welcome via PRs
Maintained by: Ven0m0 Repository: https://github.com/Ven0m0/PKG Last Updated: 2025-12-24