How do I edit PKGBUILD?
Srry if I'm a total noob but just got my first arch-install.
I'm having problem with showing some symbols in my terminal (urxvt). I searched the web and found this potential solution saying:
" In the PKGBUILD under build():
Change
--disable-frills
to
--enable-frills
--enable-unicode3
"
I have no idea how to do this, I've looked at the wiki but still aren't sure how to do it. I know that when installing packages from yaourt I usually get the option to edit PKGBUILD but sadly that option isn't available when installing urxvt. Plz help a new arch linux user :)
About this post
- Posted
- Archived
- Score
- 8 · 100% up
- Kind
- Text
- ID
- 3pgtd3
20 comments
PKGBUILD is a text file that can be edited with a text editor.
Install packages manually until you understand the process.
Since you use
yaourt:And as advised by /r/moonarch, try to understand what's actually happening when you're building (AUR) packages instead of blindly relying on AUR helpers.
Really that? Fastest way is
It will ask to modify PKGBUILD
I'm more used to downloading PKGBUILDs and keeping the source around for testing until I'm sure it satisfies me (e.g. for ffmpeg), hence the 2-step process, but thanks for pointing that out since he apparently knows exactly what to change :)
You've got lots of answers regarding how to fix your problem, but I figured I could still explain why Yaourt isn't giving you an option to edit the PKGBUILD.
The more commonly used packages are maintained by a set of people called package maintainers. When new versions of the software get released, they make sure the PKGBUILD is updated, but rather than requiring every user to recompile the package, they also upload a pre-compiled package to the Arch repositories.
When installing "rxvt-unicode", that's a pre-compiled package available in the Arch Community repo. Because of this, Yaourt never downloads a PKGBUILD (instead it tells Pacman to install the pre-compiled package straight from the repository), so obviously doesn't give you a chance to edit it.
https://wiki.archlinux.org/index.php/Arch_Build_System
It is very obvious that you do not understand the build process. I would compiling packages manually (via makepkg) until then.
If it's a pre complied package not in AUR then you probably won't get the option
Ahh, there's ABS for such a scenario if the package came from the official repos..
True.. I should have suggested that.. ABS will work for this
Download a fresh tar file from the AUR.
cd to its location in CLI and use "tar -xvf <filename>"
cd into the folder.
"sudo nano PKGBUILD"
Make your changes.
Ctrl-o to save changes; Ctrl-x to exit nano.
"makepkg PKGBUILD"
"sudo pacman -U <newfilename-1>"
sudois usually not needed here - unless you're storing your PKGBUILDs in places that your normal user can't access.Ah yeah that's true. "sudo nano" is like a muscle memory reflex from the installation process. Also having checked the wiki "makepkg PKGBUILD" appears to be a slightly outdated way of compiling the package, but it should work fine here.
thank you!