PKGNAME=git-branchless
PKGSEC=devel
PKGDES="High-velocity, monorepo-scale workflow for Git"
PKGDEP="git gcc-runtime libgit2 zlib pcre2"
BUILDDEP="rustc llvm"

USECLANG=1
ABSPLITDBG=0

# FIXME: Too many dependencies on old versions of nix...
# ... which has no LoongArch support until 0.27.0
# https://github.com/nix-rust/nix/pull/2045
#
# FIXME: on mips64el-like architectures, both CFLAGS and CXXFLAGS contain -fPIC, but...
# error: linking with `clang` failed: exit status: 1
#   |
#   = note: ld.lld: error: relocation R_MIPS_64 cannot be used against symbol 'DW.ref.rust_eh_personality'; recompile with -fPIC
#           >>> defined in /usr/lib64/rustlib/mips64el-unknown-linux-gnuabi64/lib/libstd-6dcaeb4e3195ef4c.rlib(std-6dcaeb4e3195ef4c.std.fc0db18c60d19c82-cgu.0.rcgu.o)
#           >>> referenced by std.fc0db18c60d19c82-cgu.0
#           >>>               std-6dcaeb4e3195ef4c.std.fc0db18c60d19c82-cgu.0.rcgu.o:(.eh_frame+0x37B3) in archive /usr/lib64/rustlib/mips64el-unknown-linux-gnuabi64/lib/libstd-6dcaeb4e3195ef4c.rlib
FAIL_ARCH="@(loongarch64|loongarch64_nosimd|loongson3)"
