I've gotten fbp to build on Arch using the pkgbuild in the pr below, but am having trouble figuring out how to autostart fbp on boot. Looking at the post install script in the pmOS repo, it seems like it just adds the fbp services to OpenRC's list of services to start at boot. Looking through the list of systemd services on my Pinephone, i don't see a service listed for fbp. Am i missing something? Or do I need to create a systemd service so that I can start that on boot? Thanks.
Pull request (in progress) - https://github.com/dreemurrs-embedded/Pine64-Arch/pull/344
-Bobby
On Sat, Mar 12, 2022, at 1:43 PM, Bobby Hamblin wrote:
> I've gotten fbp to build on Arch using the pkgbuild in the pr below, > but am having trouble figuring out how to autostart fbp on boot. > Looking at the post install script in the pmOS repo, it seems like it > just adds the fbp services to OpenRC's list of services to start at > boot. Looking through the list of systemd services on my Pinephone, i > don't see a service listed for fbp. Am i missing something? Or do I > need to create a systemd service so that I can start that on boot? > Thanks.> Pull request (in progress) - > https://github.com/dreemurrs-embedded/Pine64-Arch/pull/344> -Bobby
Hi Bobby,
Thanks for taking an initial stab at the Arch packaging & sending
link. Indeed you'd want to make a systemd service I believe as part of
the fbp package itself. The service file for fbp would be pretty simple
I'd imagine - just essentially making sure the ExecStart line is there -
but it's been a while since I've played with systemd. Check out the tinydm
service for something similar (although that service file is probably alot
more complex then whats needed for fbp):
https://github.com/dreemurrs-embedded/Pine64-Arch/blob/7c56526c0c5c1be8f3287bc0569d2f63befcbfa6/PKGBUILDS/sxmo/tinydm/tinydm.service
Also worth mentioning since you're working on packaging on Arch, I'm
planning to upgrade fbp to build against Zig 0.9 sometime this week since
Alpine's finally updated. Will tag a new version of fbp when updated. This
should put things in a better state for Arch too since they're on Zig 0.9.
Miles
On Sun, Mar 13, 2022, at 11:57 AM, Miles Alan wrote:
> On Sat, Mar 12, 2022, at 1:43 PM, Bobby Hamblin wrote:>> I've gotten fbp to build on Arch using the pkgbuild in the pr below, >> but am having trouble figuring out how to autostart fbp on boot. >> Looking at the post install script in the pmOS repo, it seems like it >> just adds the fbp services to OpenRC's list of services to start at >> boot. Looking through the list of systemd services on my Pinephone, i >> don't see a service listed for fbp. Am i missing something? Or do I >> need to create a systemd service so that I can start that on boot? >> Thanks.>> Pull request (in progress) - >> https://github.com/dreemurrs-embedded/Pine64-Arch/pull/344>> -Bobby>> Hi Bobby,>> Thanks for taking an initial stab at the Arch packaging & sending> link. Indeed you'd want to make a systemd service I believe as part of> the fbp package itself. The service file for fbp would be pretty simple> I'd imagine - just essentially making sure the ExecStart line is there -> but it's been a while since I've played with systemd. Check out the tinydm> service for something similar (although that service file is probably alot> more complex then whats needed for fbp):>> https://github.com/dreemurrs-embedded/Pine64-Arch/blob/7c56526c0c5c1be8f3287bc0569d2f63befcbfa6/PKGBUILDS/sxmo/tinydm/tinydm.service>> Also worth mentioning since you're working on packaging on Arch, I'm> planning to upgrade fbp to build against Zig 0.9 sometime this week since> Alpine's finally updated. Will tag a new version of fbp when updated. This> should put things in a better state for Arch too since they're on Zig 0.9.>> Miles
Just tagged 0.5 for fbp which builds against Zig 0.9.1 which should be
default for Arch.
Miles
Good evening Miles,
> Just tagged 0.5 for fbp which builds against Zig 0.9.1 which should> be default for Arch.
Thanks! I tested and updated my pr to fbp 0.5 and it works as
expected as long as Zig 0.9.1 is installed beforehand.
I figured out systemd stuff enough to make a post-install script that
enabled the fbp systemd service on boot, and fbp now behaves exactly
like it does on pmOS to my knowledge. It automatically starts on boot
with no extra tinkering needed, just run makepkg. I've updated the top
comment on my pr to reflect the current state of things.
I apologize for my long break from porting, school got crazy and time
got limited. I read (and hope i got right this time) the sr.ht mailing
list etiquette. I've started work making PKGBUILDs for each f_script,
and once I get them all functional I'll create a gen_alpinepackage
equivalent for arch. The problem there is that arch linux has no
subpackage support, so I can't make a single PKGBUILD that has the
ability to install all f_scripts, I'll have to generate the f_script
PKGBUILDs as seperate individual files. I hope this isn't too much of
an issue.
Thanks,
Bobby
On Wed, May 11, 2022, at 12:06 AM, Bobby Hamblin wrote:
> Good evening Miles,>>> Just tagged 0.5 for fbp which builds against Zig 0.9.1 which should>> be default for Arch.>> Thanks! I tested and updated my pr to fbp 0.5 and it works as> expected as long as Zig 0.9.1 is installed beforehand.>> I figured out systemd stuff enough to make a post-install script that> enabled the fbp systemd service on boot, and fbp now behaves exactly> like it does on pmOS to my knowledge. It automatically starts on boot> with no extra tinkering needed, just run makepkg. I've updated the top> comment on my pr to reflect the current state of things.>> I apologize for my long break from porting, school got crazy and time> got limited. I read (and hope i got right this time) the sr.ht mailing> list etiquette. I've started work making PKGBUILDs for each f_script,> and once I get them all functional I'll create a gen_alpinepackage> equivalent for arch. The problem there is that arch linux has no> subpackage support, so I can't make a single PKGBUILD that has the> ability to install all f_scripts, I'll have to generate the f_script> PKGBUILDs as seperate individual files. I hope this isn't too much of> an issue.>> Thanks,> Bobby
Hi Bobby,
Thanks for your work on the Arch port, and no problem at all on delay.
Indeed that's annoying that Arch doesn't support subpackages; but
yes a function to generate the f_script PKGBUILDs separately would be
welcomed. Something like a gen_archpackages function. Let me know if you
need any guidance on my end.
Miles
Hey Miles,
The porting process is coming along well. Framebufferphone is the
first software I've ported and I'm continually learning about the Arch
packaging system. I'm happy to report progress on many f_scripts, with
a few working completely as intended to my knowledge.
I've submitted linuxconsoletools and pinephone-call-audio (depends of
f_audio) to the AUR. I've also started maintaining libnsfb, a netsurf-
framebuffer dependency. I intend to do the same with netsurf-
framebuffer as soon as I get a working PKGBUILD. I got directfb to
update it's supported architectures to include aarch64, and left a
comment on the aur repo of fluxcomp to do the same. This is so that
when installing these dependencies of scripts the user doesn't have to
ignore architecture restrictions with these packages.
On the topic of netsurf-framebuffer, that package is a piece of work
on Arch, and is preventing me from building f_web. I not only had to
update it, but the PKGBUILD was (is?) missing dependencies and was
poorly formatted. It required a patch to be modified and still does not
build with an error message pertaining to missing Noto fonts. I've
installed the full noto-fonts package yet the error still does not
resolve, so I'm working on debugging that further.
Many f_scripts have command subs through the usage of $(...). This is
disallowed by setting strict-errexit in oil on the second line of each
script, and causes errors in many scripts. Either these scripts must
be restructured to not use command subs or this line should be edited.
I've made an Arch specific patch to f_phone, with minor fixes
pertaining to differences between Arch and Alpine. I've already made my
first call from f_phone as well as my first text. Hooray! The only
issue I'm getting with f_phone is that the script tries to add the user
to the plugdev group every time the script is run, as the
installpolkitudevrules() function seems to be triggered whether the
user is a part of the plugdev group or not. I'm sure this'll be an easy
fix somewhere, I just have to figure out where.
I edited the existing moon-buggy pkgbuild to update some build scripts
and add aarch64 to the supported architectures. I left a comment on the
AUR moon-buggy package drawing attention to these changes, but they
have yet to be accepted. Currently no fonts are shown in the font
changing function of f_theme, so since the default font on the Arch
linux tty is really small, I'll figure out a way to add a larger font
to the options in f_theme.
On the Zig front, it's still not updated to 0.9.1 on the Arch Linux ARM
aarch64 repository. I've added more information in the top comment of
my pr and added it to my todo list.
I added a patch that overrides the default power button behavior on
Arch to ignore the keypress. This hands the power button function over
to fbp which is the intended behavior. The default behavior is to power
down the phone whenever the power button is pressed, but I patched this
out and I can't find any other bugs in fbp itself.
One last piece of good news, Aren told me about split package support
on Arch! Apperently I didn't read the makepkg man page fully enough,
because it's well documented. I'll reformat the current pkgbuilds to
fall under a single package once I get them all to build.
That's it for this progress update, I'm continually updating the first
comment of my pr with information as i find and fix packaging issues.
Thanks,
Bobby