You are not logged in.

#1 2025-07-17 07:33:44

mass_t
Member
Registered: 2015-04-21
Posts: 84

[Solved] How to pass environment variable?

Hello! I'm trying to build this package https://aur.archlinux.org/packages/electrs-git, there is a build error in

electrs-rocksdb

. It is solved by passing an environment variable https://github.com/facebook/rocksdb/iss … 2833978676, I checked this by compiling the program from github

git clone https://github.com/romanz/electrs && cd electrs && export CXXFLAGS="$CXXFLAGS -include cstdint" cargo b --release

. But, when I put

export CXXFLAGS="$CXXFLAGS -include cstdint"

and

makepkg

-- no effect, build fail. So, how I can pass env var to makepkg?

Last edited by mass_t (2025-07-17 12:28:33)

Offline

#2 2025-07-17 07:44:16

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 71,578

Re: [Solved] How to pass environment variable?

Edit the PKGBUILD before running makepkg

Online

#3 2025-07-17 07:48:29

Lone_Wolf
Administrator
From: Netherlands, Europe
Registered: 2005-10-04
Posts: 14,565

Re: [Solved] How to pass environment variable?

That needs to be set in the build() function of the PKGBUILD.


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

#4 2025-07-17 08:02:45

mass_t
Member
Registered: 2015-04-21
Posts: 84

Re: [Solved] How to pass environment variable?

Lone_Wolf wrote:

That needs to be set in the build() function of the PKGBUILD.

Thanks, this works.

Offline

#5 2025-07-17 10:18:55

seth
Member
From: Don't DM me only for attention
Registered: 2012-09-03
Posts: 71,578

Re: [Solved] How to pass environment variable?

Please always remember to mark resolved threads by editing your initial posts subject - so others will know that there's no task left, but maybe a solution to find.
Thanks.

Online

Board footer

Powered by FluxBB