Prerequisites
System Requirements
- Go 1.14 or later
- GTK+ 3 development libraries
- Ayatana AppIndicator development libraries
- Standard build tools (gcc, make, etc.)
Supported Distributions
WireGuird has been tested on:- Ubuntu 18.04 LTS, 20.04 LTS, 21.04, 22.04 LTS, 22.10, 23.04
- Linux Mint 21.1
- Debian-based distributions
Fedora support is planned but not yet implemented. The build scripts currently only support Debian/Ubuntu-based distributions.
Installing Build Dependencies
What deps.sh Installs
Thedeps.sh script installs the following packages on Ubuntu/Debian:
wireguard-tools- Required forwgandwg-quickcommandslibgtk-3-dev- GTK+ 3 development headerslibayatana-appindicator3-dev- System tray indicator development librariesgolang-go- Go compiler and toolchainresolvconf- DNS resolution management (runtime dependency)
Building the Application
Generate resources
WireGuird uses
fileb0x to embed static resources (icons, glade files) into the binary. This is handled automatically by the build process via go generate.Build Process Details
Thepackage_deb.sh script performs these steps:
-ldflags "-s -w"- Strip debugging information and symbol table (reduces binary size)-trimpath- Remove file system paths from the binary (improves reproducibility)
Installing
Installation Locations
After installation, files are located at:- Binary:
/opt/wireguird/wireguird - Icons:
/opt/wireguird/Icon/ - Settings:
/opt/wireguird/wireguird.settings - Desktop entry:
/usr/share/applications/wireguird.desktop
Manual Build (Without .deb)
If you prefer to build without creating a package:Build Artifacts
After a successful build, you’ll have:build/wireguird_1.1.0_amd64.deb- Installable Debian package (~2.6 MB)deb/opt/wireguird/wireguird- Compiled binary
Customizing the Build
Changing the Version
Editpackage_deb.sh and update the VERSION variable:
deb/DEBIAN/control:
Modifying Build Flags
You can add additional build flags inpackage_deb.sh:
Troubleshooting Build Issues
go: command not found
go: command not found
The Go toolchain is not installed or not in your PATH.Solution:Or download the latest version from golang.org.
Package gtk-3.0 was not found
Package gtk-3.0 was not found
GTK+ 3 development libraries are missing.Solution:
cannot find package github.com/UnnoTed/fileb0x
cannot find package github.com/UnnoTed/fileb0x
Go modules need to be downloaded.Solution:
dpkg-deb: error: failed to open package info file
dpkg-deb: error: failed to open package info file
The
deb/DEBIAN/control file is missing or malformed.Solution:
Ensure the control file exists with correct format. Check that you haven’t modified the package structure.Development Build
For development purposes, you can build without optimizations:Next Steps
After building:- See Dependencies for runtime requirements
- Check Troubleshooting for common issues
- Review the Settings guide for configuration
