Bug#1004114: llvm-toolchain source package rules 'NJOBS' missing '-j'
YumeYao
yumeyao at gmail.com
Fri Jan 21 01:59:56 GMT 2022
Source: llvm-toolchain-13
Version: 1:13.0.1~+rc1-1~exp4
When building llvm-toolchain-12 and/or llvm-toolchain-13, the build
fails with following error message:
LD_LIBRARY_PATH=/PRIVACY_INFO/llvm-toolchain-12_12.0.1/build-llvm/lib:$LD_LIBRARY_PATH
\
VERBOSE=1 cmake --build build-llvm 16 --target stage2
Unknown argument 16
This is defined in debian-full-build target within rules:
debian-full-build:
echo "Using cmake: $(CMAKE_BIN)"
# linker hack so stage2 can link against stage1 libs at runtime
LD_LIBRARY_PATH=$(STAGE_1_LIB_DIR):$$LD_LIBRARY_PATH \
VERBOSE=1 $(PRE_PROCESS) $(CMAKE_BIN) --build $(TARGET_BUILD) $(NJOBS)
--target stage2
whereas $(NJOBS) is defined as
ifneq (,$(filter parallel=%,$(subst $(COMMA), ,$(DEB_BUILD_OPTIONS))))
NJOBS := -j $(subst parallel=,,$(filter parallel=%,$(subst $(COMMA),
,$(DEB_BUILD_OPTIONS))))
else
NJOBS := $(shell nproc)
endif
I'm aware that I can set an envvar DEB_BUILD_OPTIONS='parallel=XX'
before the build, but I assume the proper fix for it should be:
else
NJOBS := -j $(shell nproc)
endif
Regards,
yumeyao
More information about the Pkg-llvm-team
mailing list