You are not logged in.

#1 2022-08-18 21:58:07

Registered: 2021-12-18
Posts: 6

[SOLVED] PKGBUILD review request: kaarten-deno

Hi all,

Working on building a PKGBUILD for a small project I administer. It's written in deno; source files below.

Here's the pkgbuild:

#Maintainer: Alex S. <alex at panoptic dot onl>
pkgdesc="A Kaarten is a digital csv database which supplements your analog notebook."
build() {
	cd "$srcdir/kaarten-deno-v$pkgver"
	deno compile --reload --output "../kaarten" --target x86_64-unknown-linux-gnu --allow-read --allow-write kaarten.ts
package() {
	cd "$srcdir"
	install -Dm777 kaarten "$pkgdir/usr/bin/kaarten"

There's a very bizarre issue I'm facing that I can't make heads or tails of - the compile process in build() works - but it breaks in package(). If I run the outputted binary in the src/ folder, it executes properly - however if I try to install the outputted package, or run the binary after it's been "installed" to the pkg/ directory, the same file now drops directly to the deno runtime - as if I had simply executed "deno" with no arguments, instead of running my compiled script.

Can anyone give me pointers on what I'm doing wrong, or how to find out what I'm doing wrong?

Thanks in advance.

Update 1: The installed package is 30MB smaller then the full binary; which may explain something. What isn't explained yet is why this filesize drop only happens in the false root, not when I "install" the binary manually.

Update 2: Enabling !strip in options() allows the package to be moved normally. Unsure what flags makepkg is stripping that causes it to fail; but it mangles the binary file.

Last edited by ChilledTonic (2022-08-19 01:05:01)


Board footer

Powered by FluxBB