You are not logged in.
Pages: 1
Topic closed
Hi,
I just rediscovered option -j in make, that lets make runs parallel jobs. On my computer (4 cores, ssd), it speeds up things.
I was wondering if it was clean/permitted/a good idea to use this in PKGBUILDs, by automatically adjusting the -j parameter to the number of cores, or half the number of cores ?
Cheers,
Charles
Last edited by cgo (2014-03-12 12:48:45)
Offline
This should not be added to PKGBUILDs. Makepkg already sets this if the user has opted for it in /etc/makepkg.conf. If you try to override this you will be using a setting that works best on your machine to override a setting the user has found works best on their own machine.
For your own use, just set -j4 in makepkg.conf on your system.
Last edited by Trilby (2014-03-12 12:11:04)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Hi,
thanks, I should have checked in makepkg.conf (MAKEFLAGS option).
It's great it already exists !
Enjoy,
Charles
Offline
There is one exception, -j1 can be used in a PKGBUILD to limit the number of threads, e.g. if the build fails due to some race conditions in the build process.
Offline
There is one exception, -j1 can be used in a PKGBUILD to limit the number of threads, e.g. if the build fails due to some race conditions in the build process.
There is even an option.... Add options=('!makeflags') to the PKGBUILD
Offline
This should not be added to PKGBUILDs. Makepkg already sets this if the user has opted for it in /etc/makepkg.conf. If you try to override this you will be using a setting that works best on your machine to override a setting the user has found works best on their own machine.
For your own use, just set -j4 in makepkg.conf on your system.
For setting it for a specific user you should instead modify ~/.config/pacman/makepkg.conf.
Offline
Yes, but that feature has not been temporally back-ported to 11 years ago.
#RetconMakepkg
Last edited by Trilby (2025-02-19 13:48:57)
"UNIX is simple and coherent" - Dennis Ritchie; "GNU's Not Unix" - Richard Stallman
Offline
Please don't necro-bump
Closing this thread.
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Pages: 1
Topic closed