Package Details: python-xgboost 3.1.3-1

Git Clone URL: https://aur.archlinux.org/python-xgboost.git (read-only, click to copy)
Package Base: python-xgboost
Description: Gradient Boosting Library for Python
Upstream URL: https://xgboost.ai
Licenses: Apache-2.0
Submitter: a.kudelin
Maintainer: a.kudelin
Last Packager: a.kudelin
Votes: 4
Popularity: 0.000000
First Submitted: 2023-01-29 19:36 (UTC)
Last Updated: 2026-01-17 16:59 (UTC)

Latest Comments

Mitmischer commented on 2026-02-11 18:01 (UTC)

I needed to add -DCMAKE_CXX_FLAGS="--fno-char8_t" in build() to get this package to compile. I also added "-w" to get rid of the myriad of warnings that occur during compilation.

hockeymikey commented on 2026-02-03 15:33 (UTC)

Builds are failing for me.

FAILED: [code=1] src/CMakeFiles/objxgboost.dir/common/json.cc.o /usr/bin/c++ -DDMLC_CORE_USE_CMAKE -DDMLC_LOG_CUSTOMIZE=1 -DDMLC_USE_CXX11=1 -DDMLC_USE_CXX14=1 -DPROTOBUF_USE_DLLS -DXGBOOST_BUILTIN_PREFETCH_PRESENT=1 -DXGBOOST_MM_PREFETCH_PRESENT=1 -DXGBOOST_USE_FEDERATED=1 -D_MWAITXINTRIN_H_INCLUDED -D__USE_XOPEN2K8 -I/home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/include -I/home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/dmlc-core/include -I/home/hockeymikey/.cache/yay/python-xgboost/src/build/dmlc-core/include -I/home/hockeymikey/.cache/yay/python-xgboost/src/build/plugin/federated -march=x86-64 -mtune=generic -O2 -pipe -fno-plt -O3 -DNDEBUG -std=gnu++20 -fPIC -funroll-loops -fopenmp -MD -MT src/CMakeFiles/objxgboost.dir/common/json.cc.o -MF src/CMakeFiles/objxgboost.dir/common/json.cc.o.d -o src/CMakeFiles/objxgboost.dir/common/json.cc.o -c /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/src/common/json.cc In file included from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/dmlc-core/include/dmlc/./json.h:25, from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/dmlc-core/include/dmlc/parameter.h:27, from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/include/xgboost/parameter.h:11, from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/include/xgboost/logging.h:15, from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/include/xgboost/json.h:8, from /home/hockeymikey/.cache/yay/python-xgboost/src/xgboost-3.1.3/src/common/json.cc:4:

Not really sure where in this stack though. Anyone else running into this?

rod2ik commented on 2026-01-04 14:34 (UTC) (edited on 2026-01-04 14:36 (UTC) by rod2ik)

If you receive some errors during the check() function, you can avoid online check() and concentrate only on offline checks, by replacing the check() function in the PKGBUILD by the following:

check() {
  cd $_pyname-$pkgver

  python -m venv --system-site-packages test-env
  source test-env/bin/activate
  python -m installer python-package/dist/*.whl

  # Offline smoke tests (no sklearn datasets download)
  python - <<'PY'
import xgboost as xgb
import numpy as np

X = np.random.RandomState(0).rand(100, 10).astype(np.float32)
y = (X[:, 0] + X[:, 1] > 1.0).astype(np.float32)

dtrain = xgb.DMatrix(X, label=y)
bst = xgb.train({"max_depth": 3, "eta": 0.1, "objective": "binary:logistic"}, dtrain, num_boost_round=5)
pred = bst.predict(dtrain)
assert pred.shape == (100,)
print("xgboost smoke test OK")
PY

  deactivate
}

Indeed, this latter proposed check() function:

  • Verifies the built wheel imports
  • Verifies training + prediction works
  • Requires no network
  • Avoids the sklearn API mismatch tests entirely

This is a common packaging pattern when upstream tests are flaky or networked.

angelodalzotto commented on 2024-03-05 23:52 (UTC)

Can't build anymore due to openmpi, maybe we can't fix in PKGBUILD until a fix comes from the upstream