A surgical binary patcher that removes LGBT pride theme options from the Bazaar GNOME application store.
Bazaar includes 11 pride flag themes for its progress bar (rainbow, lesbian, transgender, nonbinary, bisexual, asexual, pansexual, aromantic, genderfluid, polysexual, and omnisexual). This tool removes all of them from the compiled binary, leaving only the default "Accent Color" theme.
- No recompilation needed - patches the installed binary directly
- High performance - uses memory-mapped I/O for efficient patching
- No backups - permanently removes themes from your system
- Auto-detection - finds Bazaar installation automatically (Flatpak or system)
- Linux system with Bazaar installed
- GCC compiler
- Root/sudo access (to modify system binaries)
gcc -O3 -march=native -flto -Wall -Wextra -o bazaar_patcher bazaar_patcher.c# Auto-detect Bazaar installation and patch
sudo ./bazaar_patcher
# Or specify path manually
sudo ./bazaar_patcher /usr/local/bin/bazaar
# For Flatpak installations
sudo ./bazaar_patcher /var/lib/flatpak/app/io.github.kolunmi.Bazaar/current/active/files/bin/bazaarImportant: Close Bazaar before running the patcher.
- Locates the Bazaar binary (Flatpak or system installation)
- Memory-maps the binary file for efficient I/O
- Searches for all pride theme string literals
- Overwrites them with null bytes (0x00)
- Syncs changes to disk
- The UI will only show "Accent Color" as available theme
The patcher targets hardcoded theme definitions in the binary:
static const BarTheme bar_themes[] = {
{ "accent-color", "accent-color-theme", N_ ("Accent Color") },
{ "pride-rainbow-flag", "pride-rainbow-theme", N_ ("Pride Colors") },
// ... etc
};It nulls out all non-default theme strings, effectively removing them from the array without corrupting the binary structure.
- You'll need to re-run this after any Bazaar updates
- The patched binary is permanent (no backups created)
- May not work if Bazaar changes its internal structure in future versions
Honestly, because C is pretty great.
This modifies application binaries. Use at your own risk. If you break your Bazaar installation, just reinstall it.