Makepkg makepkg.conf Optimizations
Tags arch, archlinux, makepgk, optimizations, pacman
Here are my /etc/makepkg.conf Optimizations
Makepkg.conf is used whenever you build a package from the Aur or any other source. (makepkg -si)
1) Set -march and -mtune to native to optimize packages to your CPU architecture.
Do not fiddle with this if you are building packages for someone else who has different CPU
2) Define how many CPU threads to use when building a package (-j[number of threads]) Set to the number of threads your CPU has for optimal results. Some suggest adding one more (n + 1) but I haven't tested it.
3) Enable ccache to speed up rebuilds and incremental updates.
First you need to install ccache package.
Then modify BUILDENV variable in makepkg.conf. Change !ccache to ccache.
4) Disable packages compression, it is a waste of time. We don't care about the size and we have plenty of bandwidth and HDD space. Compressing a package can take several minutes on low end computers which is annoying.
Change the pkg extension from xz to tar
If you know more optimizations, let me know!
Makepkg.conf is used whenever you build a package from the Aur or any other source. (makepkg -si)
1) Set -march and -mtune to native to optimize packages to your CPU architecture.
Do not fiddle with this if you are building packages for someone else who has different CPU
Code:
CFLAGS="-march=native -mtune=native -O2 -pipe -fstack-protector-strong --param=ssp-buffer-size=4" CXXFLAGS="-march=native -mtune=native -O2 -pipe -fstack-protector-strong --param=ssp-buffer-size=4"
Code:
MAKEFLAGS="-j2"
First you need to install ccache package.
Code:
pacman -Syu ccache
Code:
BUILDENV=(!distcc color ccache check !sign)
Change the pkg extension from xz to tar
Code:
PKGEXT='.pkg.tar'
Total Comments 0