[packages/dmlc-core] - new

qboosh qboosh at pld-linux.org
Sat May 16 18:47:06 CEST 2026


commit dfdee74e55ca8e329ce578df1e66be9f9d84faed
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date:   Sat May 16 18:46:58 2026 +0200

    - new

 dmlc-core-no-forced-sse2.patch |  13 +++++
 dmlc-core.spec                 | 120 +++++++++++++++++++++++++++++++++++++++++
 2 files changed, 133 insertions(+)
---
diff --git a/dmlc-core.spec b/dmlc-core.spec
new file mode 100644
index 0000000..3e5c9a3
--- /dev/null
+++ b/dmlc-core.spec
@@ -0,0 +1,120 @@
+# TODO:
+# USE_HDFS (BR: hdfs.h, libhdfs, hadoop executable, JDK/JNI)
+# USE_AZURE (BR: cpprestsdk, azure-storage-cpp)
+#
+# Conditional build:
+%bcond_without	apidocs		# API documentation
+%bcond_without	openmp		# OpenMP support
+%bcond_without	s3		# S3 storage support
+#
+Summary:	Distributed Machine Learning Common Codebase
+Summary(pl.UTF-8):	Distributed Machine Learning Common Codebase - wspólna biblioteka do rozproszonego uczenia maszynowego
+Name:		dmlc-core
+Version:	0.5
+Release:	1
+License:	Apache v2.0
+Group:		Libraries
+#Source0Download: https://github.com/dmlc/dmlc-core/tags
+Source0:	https://github.com/dmlc/dmlc-core/archive/v%{version}/%{name}-%{version}.tar.gz
+# Source0-md5:	5b2b24ab4dd39db51c53ef5e780ed8e2
+Patch0:		%{name}-no-forced-sse2.patch
+URL:		https://github.com/dmlc/dmlc-core
+BuildRequires:	cmake >= 3.2
+%{?with_s3:BuildRequires:	curl-devel}
+%{?with_openmp:BuildRequires:	libgomp-devel}
+BuildRequires:	libstdc++-devel >= 6:5
+%{?with_s3:BuildRequires:	openssl-devel}
+BuildRequires:	rpm-build >= 4.6
+BuildRequires:	rpmbuild(macros) >= 1.605
+%if %{with apidocs}
+BuildRequires:	doxygen
+BuildRequires:	python3-breathe
+BuildRequires:	python3-recommonmark
+BuildRequires:	sphinx-pdg >= 2
+%endif
+BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+DMLC-Core is the backbone library to support all DMLC projects, offers
+the bricks to build efficient and scalable distributed machine
+learning libraries.
+
+%description -l pl.UTF-8
+DMLC-Core to biblioteka szkieletowa wspierająca wszystkie projekty
+DMLC, oferująca cegiełki pozwalające budować wydajne i skalowalne
+biblioteki do rozproszonego uczenia maszynowego.
+
+%package devel
+Summary:	Header files for DMLC-Core library
+Summary(pl.UTF-8):	Pliki nagłówkowe biblioteki DMLC-Core
+Group:		Development/Libraries
+Requires:	%{name} = %{version}-%{release}
+%{?with_openmp:Requires:	libgomp-devel}
+Requires:	libstdc++-devel >= 6:5
+
+%description devel
+Header files for DMLC-Core library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki DMLC-Core.
+
+%package apidocs
+Summary:	API documentation for DMLC-Core library
+Summary(pl.UTF-8):	Dokumentacja API biblioteki DMLC-Core
+Group:		Documentation
+BuildArch:	noarch
+
+%description apidocs
+API documentation for DMLC-Core library.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API biblioteki DMLC-Core.
+
+%prep
+%setup -q
+%patch -P0 -p1
+
+%build
+install -d build
+cd build
+%cmake .. \
+	-DDMLC_HDFS_SHARED=ON \
+	%{!?with_openmp:-DUSE_OPENMP=OFF} \
+	%{?with_s3:-DUSE_S3=ON} \
+	-DUSE_CXX14_IF_AVAILABLE=ON
+
+%{__make}
+cd ..
+
+%if %{with apidocs}
+%{__make} -C doc html
+%{__rm} -r doc/_build/html/doxygen/*.{map,md5}
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} -C build install \
+	DESTDIR=$RPM_BUILD_ROOT
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post	-p /sbin/ldconfig
+%postun	-p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc README.md
+%{_libdir}/libdmlc.so
+
+%files devel
+%defattr(644,root,root,755)
+%{_includedir}/dmlc
+%{_libdir}/cmake/dmlc
+
+%if %{with apidocs}
+%files apidocs
+%defattr(644,root,root,755)
+%doc doc/_build/html/{_static,doxygen,*.html,*.js}
+%endif
diff --git a/dmlc-core-no-forced-sse2.patch b/dmlc-core-no-forced-sse2.patch
new file mode 100644
index 0000000..bfcbfaf
--- /dev/null
+++ b/dmlc-core-no-forced-sse2.patch
@@ -0,0 +1,13 @@
+--- dmlc-core-0.5/CMakeLists.txt.orig	2026-05-16 17:51:52.509372956 +0200
++++ dmlc-core-0.5/CMakeLists.txt	2026-05-16 17:52:05.775967751 +0200
+@@ -191,10 +191,6 @@ if(MSVC)
+   set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} /EHsc")
+ else()
+   set(CMAKE_POSITION_INDEPENDENT_CODE ON)
+-  check_cxx_compiler_flag("-msse2" SUPPORT_MSSE2)
+-  if(SUPPORT_MSSE2)
+-    target_compile_options(dmlc PRIVATE -msse2)
+-  endif()
+   target_compile_options(dmlc PRIVATE -Wall -Wno-unknown-pragmas -fPIC)
+   if(CMAKE_BUILD_TYPE STREQUAL "DEBUG" OR CMAKE_BUILD_TYPE STREQUAL "Debug")
+     target_compile_options(dmlc PRIVATE -g -O0)
================================================================

---- gitweb:

http://git.pld-linux.org/gitweb.cgi/packages/dmlc-core.git/commitdiff/dfdee74e55ca8e329ce578df1e66be9f9d84faed



More information about the pld-cvs-commit mailing list