Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 14 Dec 2019 22:12:33 +0000 (UTC)
From:      Yuri Victorovich <yuri@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r520146 - in head/misc: . py-xgboost py-xgboost/files
Message-ID:  <201912142212.xBEMCXNf017756@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: yuri
Date: Sat Dec 14 22:12:32 2019
New Revision: 520146
URL: https://svnweb.freebsd.org/changeset/ports/520146

Log:
  New port: misc/py-xgboost: Scalable, Portable and Distributed Gradient Boosting (GBDT, GBRT, GBM)

Added:
  head/misc/py-xgboost/
  head/misc/py-xgboost/Makefile   (contents, props changed)
  head/misc/py-xgboost/distinfo   (contents, props changed)
  head/misc/py-xgboost/files/
  head/misc/py-xgboost/files/patch-xgboost_libpath.py   (contents, props changed)
  head/misc/py-xgboost/pkg-descr   (contents, props changed)
Modified:
  head/misc/Makefile

Modified: head/misc/Makefile
==============================================================================
--- head/misc/Makefile	Sat Dec 14 21:46:17 2019	(r520145)
+++ head/misc/Makefile	Sat Dec 14 22:12:32 2019	(r520146)
@@ -419,6 +419,7 @@
     SUBDIR += py-toil
     SUBDIR += py-tqdm
     SUBDIR += py-tvm
+    SUBDIR += py-xgboost
     SUBDIR += py-yolk
     SUBDIR += pylize
     SUBDIR += pyobd

Added: head/misc/py-xgboost/Makefile
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/misc/py-xgboost/Makefile	Sat Dec 14 22:12:32 2019	(r520146)
@@ -0,0 +1,42 @@
+# $FreeBSD$
+
+PORTNAME=	xgboost
+DISTVERSIONPREFIX=	v
+DISTVERSION=	0.90-235
+DISTVERSIONSUFFIX=	-gad4a1c73
+CATEGORIES=	misc # machine-learning
+PKGNAMEPREFIX=	${PYTHON_PKGNAMEPREFIX}
+
+MAINTAINER=	yuri@FreeBSD.org
+COMMENT=	Scalable, Portable and Distributed Gradient Boosting (GBDT, GBRT, GBM)
+
+LICENSE=	APACHE20
+LICENSE_FILE=	${WRKSRC}/../LICENSE
+
+LIB_DEPENDS=	libdmlc.so:devel/dmlc-core \
+		librabit.so:misc/xgboost
+RUN_DEPENDS=	${PYNUMPY} \
+		${PYTHON_PKGNAMEPREFIX}scipy>0:science/py-scipy@${PY_FLAVOR}
+
+USES=		python
+USE_GITHUB=	yes
+GH_ACCOUNT=	dmlc
+USE_PYTHON=	distutils autoplist
+USE_LDCONFIG=	yes
+
+WRKSRC_SUBDIR=	python-package
+
+MAKE_ENV+=	FREEBSD_LIBRARY_PATH=${LOCALBASE}/lib
+
+NO_ARCH=	yes
+
+POST_PLIST=	fix-plist
+
+post-install:
+	@${RM} ${STAGEDIR}${PREFIX}/xgboost/libxgboost.so
+	@${RMDIR} ${STAGEDIR}${PREFIX}/xgboost
+
+fix-plist: # https://github.com/dmlc/xgboost/issues/5118
+	@${REINPLACE_CMD} -e 's|^xgboost/libxgboost.so$$||' ${TMPPLIST}
+
+.include <bsd.port.mk>

Added: head/misc/py-xgboost/distinfo
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/misc/py-xgboost/distinfo	Sat Dec 14 22:12:32 2019	(r520146)
@@ -0,0 +1,3 @@
+TIMESTAMP = 1576359661
+SHA256 (dmlc-xgboost-v0.90-235-gad4a1c73_GH0.tar.gz) = c5fd4f9c152ba56961a43b677397251f20f78e534571926247f8d24275f9642b
+SIZE (dmlc-xgboost-v0.90-235-gad4a1c73_GH0.tar.gz) = 1131611

Added: head/misc/py-xgboost/files/patch-xgboost_libpath.py
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/misc/py-xgboost/files/patch-xgboost_libpath.py	Sat Dec 14 22:12:32 2019	(r520146)
@@ -0,0 +1,11 @@
+--- xgboost/libpath.py.orig	2019-12-14 21:46:06 UTC
++++ xgboost/libpath.py
+@@ -20,7 +20,7 @@ def find_lib_path():
+     """
+     curr_path = os.path.dirname(os.path.abspath(os.path.expanduser(__file__)))
+     # make pythonpack hack: copy this directory one level upper for setup.py
+-    dll_path = [curr_path, os.path.join(curr_path, '../../lib/'),
++    dll_path = [os.getenv('FREEBSD_LIBRARY_PATH'),
+                 os.path.join(curr_path, './lib/'),
+                 os.path.join(sys.prefix, 'xgboost')]
+     if sys.platform == 'win32':

Added: head/misc/py-xgboost/pkg-descr
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/misc/py-xgboost/pkg-descr	Sat Dec 14 22:12:32 2019	(r520146)
@@ -0,0 +1,5 @@
+Scalable, Portable and Distributed Gradient Boosting (GBDT, GBRT or GBM)
+Library, for Python, R, Java, Scala, C++ and more. Runs on single machine,
+Hadoop, Spark, Flink and DataFlow.
+
+WWW: https://xgboost.ai/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201912142212.xBEMCXNf017756>