[arch-commits] Commit in libsvm/repos/community-x86_64 (8 files)

Daniel Bermond dbermond at gemini.archlinux.org
Tue Dec 14 02:46:57 UTC 2021


    Date: Tuesday, December 14, 2021 @ 02:46:56
  Author: dbermond
Revision: 1072707

archrelease: copy trunk to community-x86_64

Added:
  libsvm/repos/community-x86_64/010-libsvm-fix-qt-headers-path.patch
    (from rev 1072706, libsvm/trunk/010-libsvm-fix-qt-headers-path.patch)
  libsvm/repos/community-x86_64/020-libsvm-use-archlinux-flags.patch
    (from rev 1072706, libsvm/trunk/020-libsvm-use-archlinux-flags.patch)
  libsvm/repos/community-x86_64/030-libsvm-fix-tools-path.patch
    (from rev 1072706, libsvm/trunk/030-libsvm-fix-tools-path.patch)
  libsvm/repos/community-x86_64/PKGBUILD
    (from rev 1072706, libsvm/trunk/PKGBUILD)
Deleted:
  libsvm/repos/community-x86_64/010-libsvm-fix-qt-headers-path.patch
  libsvm/repos/community-x86_64/020-libsvm-use-archlinux-flags.patch
  libsvm/repos/community-x86_64/030-libsvm-fix-tools-path.patch
  libsvm/repos/community-x86_64/PKGBUILD

--------------------------------------+
 010-libsvm-fix-qt-headers-path.patch |   22 ++---
 020-libsvm-use-archlinux-flags.patch |   94 ++++++++++-----------
 030-libsvm-fix-tools-path.patch      |   61 ++++++-------
 PKGBUILD                             |  144 ++++++++++++++++-----------------
 4 files changed, 158 insertions(+), 163 deletions(-)

Deleted: 010-libsvm-fix-qt-headers-path.patch
===================================================================
--- 010-libsvm-fix-qt-headers-path.patch	2021-12-14 02:46:13 UTC (rev 1072706)
+++ 010-libsvm-fix-qt-headers-path.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -1,11 +0,0 @@
---- a/svm-toy/qt/Makefile
-+++ b/svm-toy/qt/Makefile
-@@ -1,7 +1,7 @@
- # use  ``export QT_SELECT=qt5'' in a command window for using qt5
- # may need to adjust the path of header files
- CXX? = g++
--INCLUDE = /usr/include/x86_64-linux-gnu/qt5
-+INCLUDE = /usr/include/qt
- CFLAGS = -Wall -O3 -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
- LIB = -lQt5Widgets -lQt5Gui -lQt5Core
- MOC = /usr/bin/moc

Copied: libsvm/repos/community-x86_64/010-libsvm-fix-qt-headers-path.patch (from rev 1072706, libsvm/trunk/010-libsvm-fix-qt-headers-path.patch)
===================================================================
--- 010-libsvm-fix-qt-headers-path.patch	                        (rev 0)
+++ 010-libsvm-fix-qt-headers-path.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -0,0 +1,11 @@
+--- a/svm-toy/qt/Makefile
++++ b/svm-toy/qt/Makefile
+@@ -1,7 +1,7 @@
+ # use  ``export QT_SELECT=qt5'' in a command window for using qt5
+ # may need to adjust the path of header files
+ CXX? = g++
+-INCLUDE = /usr/include/x86_64-linux-gnu/qt5
++INCLUDE = /usr/include/qt
+ CFLAGS = -Wall -O3 -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
+ LIB = -lQt5Widgets -lQt5Gui -lQt5Core
+ MOC = /usr/bin/moc

Deleted: 020-libsvm-use-archlinux-flags.patch
===================================================================
--- 020-libsvm-use-archlinux-flags.patch	2021-12-14 02:46:13 UTC (rev 1072706)
+++ 020-libsvm-use-archlinux-flags.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -1,47 +0,0 @@
---- a/Makefile
-+++ b/Makefile
-@@ -1,5 +1,5 @@
- CXX ?= g++
--CFLAGS = -Wall -Wconversion -O3 -fPIC
-+CFLAGS += -Wall -Wconversion -fPIC
- SHVER = 2
- OS = $(shell uname)
- 
-@@ -11,15 +11,15 @@ lib: svm.o
- 	else \
- 		SHARED_LIB_FLAG="-shared -Wl,-soname,libsvm.so.$(SHVER)"; \
- 	fi; \
--	$(CXX) $${SHARED_LIB_FLAG} svm.o -o libsvm.so.$(SHVER)
-+	$(CXX) $${SHARED_LIB_FLAG} svm.o -o libsvm.so.$(SHVER) $(LDFLAGS)
- 
- svm-predict: svm-predict.c svm.o
--	$(CXX) $(CFLAGS) svm-predict.c svm.o -o svm-predict -lm
-+	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-predict.c svm.o -o svm-predict -lm $(LDFLAGS)
- svm-train: svm-train.c svm.o
--	$(CXX) $(CFLAGS) svm-train.c svm.o -o svm-train -lm
-+	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-train.c svm.o -o svm-train -lm $(LDFLAGS)
- svm-scale: svm-scale.c
--	$(CXX) $(CFLAGS) svm-scale.c -o svm-scale
-+	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-scale.c -o svm-scale $(LDFLAGS)
- svm.o: svm.cpp svm.h
--	$(CXX) $(CFLAGS) -c svm.cpp
-+	$(CXX) $(CPPFLAGS) $(CFLAGS) -c svm.cpp
- clean:
- 	rm -f *~ svm.o svm-train svm-predict svm-scale libsvm.so.$(SHVER)
---- a/svm-toy/qt/Makefile
-+++ b/svm-toy/qt/Makefile
-@@ -2,12 +2,12 @@
- # may need to adjust the path of header files
- CXX? = g++
- INCLUDE = /usr/include/qt
--CFLAGS = -Wall -O3 -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
-+CFLAGS += -Wall -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
- LIB = -lQt5Widgets -lQt5Gui -lQt5Core
- MOC = /usr/bin/moc
- 
- svm-toy: svm-toy.cpp svm-toy.moc ../../svm.o
--	$(CXX) $(CFLAGS) svm-toy.cpp ../../svm.o -o svm-toy $(LIB)
-+	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-toy.cpp ../../svm.o -o svm-toy $(LIB) $(LDFLAGS)
- 
- svm-toy.moc: svm-toy.cpp
- 	$(MOC) svm-toy.cpp -o svm-toy.moc

Copied: libsvm/repos/community-x86_64/020-libsvm-use-archlinux-flags.patch (from rev 1072706, libsvm/trunk/020-libsvm-use-archlinux-flags.patch)
===================================================================
--- 020-libsvm-use-archlinux-flags.patch	                        (rev 0)
+++ 020-libsvm-use-archlinux-flags.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -0,0 +1,47 @@
+--- a/Makefile
++++ b/Makefile
+@@ -1,5 +1,5 @@
+ CXX ?= g++
+-CFLAGS = -Wall -Wconversion -O3 -fPIC
++CFLAGS += -Wall -Wconversion -fPIC
+ SHVER = 2
+ OS = $(shell uname)
+ 
+@@ -11,15 +11,15 @@ lib: svm.o
+ 	else \
+ 		SHARED_LIB_FLAG="-shared -Wl,-soname,libsvm.so.$(SHVER)"; \
+ 	fi; \
+-	$(CXX) $${SHARED_LIB_FLAG} svm.o -o libsvm.so.$(SHVER)
++	$(CXX) $${SHARED_LIB_FLAG} svm.o -o libsvm.so.$(SHVER) $(LDFLAGS)
+ 
+ svm-predict: svm-predict.c svm.o
+-	$(CXX) $(CFLAGS) svm-predict.c svm.o -o svm-predict -lm
++	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-predict.c svm.o -o svm-predict -lm $(LDFLAGS)
+ svm-train: svm-train.c svm.o
+-	$(CXX) $(CFLAGS) svm-train.c svm.o -o svm-train -lm
++	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-train.c svm.o -o svm-train -lm $(LDFLAGS)
+ svm-scale: svm-scale.c
+-	$(CXX) $(CFLAGS) svm-scale.c -o svm-scale
++	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-scale.c -o svm-scale $(LDFLAGS)
+ svm.o: svm.cpp svm.h
+-	$(CXX) $(CFLAGS) -c svm.cpp
++	$(CXX) $(CPPFLAGS) $(CFLAGS) -c svm.cpp
+ clean:
+ 	rm -f *~ svm.o svm-train svm-predict svm-scale libsvm.so.$(SHVER)
+--- a/svm-toy/qt/Makefile
++++ b/svm-toy/qt/Makefile
+@@ -2,12 +2,12 @@
+ # may need to adjust the path of header files
+ CXX? = g++
+ INCLUDE = /usr/include/qt
+-CFLAGS = -Wall -O3 -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
++CFLAGS += -Wall -I$(INCLUDE) -I$(INCLUDE)/QtWidgets -I$(INCLUDE)/QtGui -I$(INCLUDE)/QtCore -fPIC -std=c++11
+ LIB = -lQt5Widgets -lQt5Gui -lQt5Core
+ MOC = /usr/bin/moc
+ 
+ svm-toy: svm-toy.cpp svm-toy.moc ../../svm.o
+-	$(CXX) $(CFLAGS) svm-toy.cpp ../../svm.o -o svm-toy $(LIB)
++	$(CXX) $(CPPFLAGS) $(CFLAGS) svm-toy.cpp ../../svm.o -o svm-toy $(LIB) $(LDFLAGS)
+ 
+ svm-toy.moc: svm-toy.cpp
+ 	$(MOC) svm-toy.cpp -o svm-toy.moc

Deleted: 030-libsvm-fix-tools-path.patch
===================================================================
--- 030-libsvm-fix-tools-path.patch	2021-12-14 02:46:13 UTC (rev 1072706)
+++ 030-libsvm-fix-tools-path.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -1,33 +0,0 @@
---- a/tools/easy.py
-+++ b/tools/easy.py
-@@ -12,10 +12,10 @@ if len(sys.argv) <= 1:
- 
- is_win32 = (sys.platform == 'win32')
- if not is_win32:
--    svmscale_exe = "../svm-scale"
--    svmtrain_exe = "../svm-train"
--    svmpredict_exe = "../svm-predict"
--    grid_py = "./grid.py"
-+    svmscale_exe = "/usr/bin/svm-scale"
-+    svmtrain_exe = "/usr/bin/svm-train"
-+    svmpredict_exe = "/usr/bin/svm-predict"
-+    grid_py = "/usr/bin/svm-grid.py"
-     gnuplot_exe = "/usr/bin/gnuplot"
- else:
-         # example for windows
---- a/tools/grid.py
-+++ b/tools/grid.py
-@@ -1,3 +1,4 @@
-+
- #!/usr/bin/env python
- __all__ = ['find_parameters']
- 
-@@ -18,7 +19,7 @@ class GridOption:
-     def __init__(self, dataset_pathname, options):
-         dirname = os.path.dirname(__file__)
-         if sys.platform != 'win32':
--            self.svmtrain_pathname = os.path.join(dirname, '../svm-train')
-+            self.svmtrain_pathname = '/usr/bin/svm-train'
-             self.gnuplot_pathname = '/usr/bin/gnuplot'
-         else:
-             # example for windows

Copied: libsvm/repos/community-x86_64/030-libsvm-fix-tools-path.patch (from rev 1072706, libsvm/trunk/030-libsvm-fix-tools-path.patch)
===================================================================
--- 030-libsvm-fix-tools-path.patch	                        (rev 0)
+++ 030-libsvm-fix-tools-path.patch	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -0,0 +1,28 @@
+--- a/tools/easy.py
++++ b/tools/easy.py
+@@ -12,10 +12,10 @@ if len(sys.argv) <= 1:
+ 
+ is_win32 = (sys.platform == 'win32')
+ if not is_win32:
+-    svmscale_exe = "../svm-scale"
+-    svmtrain_exe = "../svm-train"
+-    svmpredict_exe = "../svm-predict"
+-    grid_py = "./grid.py"
++    svmscale_exe = "/usr/bin/svm-scale"
++    svmtrain_exe = "/usr/bin/svm-train"
++    svmpredict_exe = "/usr/bin/svm-predict"
++    grid_py = "/usr/bin/svm-grid.py"
+     gnuplot_exe = "/usr/bin/gnuplot"
+ else:
+         # example for windows
+--- a/tools/grid.py
++++ b/tools/grid.py
+@@ -18,7 +19,7 @@ class GridOption:
+     def __init__(self, dataset_pathname, options):
+         dirname = os.path.dirname(__file__)
+         if sys.platform != 'win32':
+-            self.svmtrain_pathname = os.path.join(dirname, '../svm-train')
++            self.svmtrain_pathname = '/usr/bin/svm-train'
+             self.gnuplot_pathname = '/usr/bin/gnuplot'
+         else:
+             # example for windows

Deleted: PKGBUILD
===================================================================
--- PKGBUILD	2021-12-14 02:46:13 UTC (rev 1072706)
+++ PKGBUILD	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -1,72 +0,0 @@
-# Maintainer : Daniel Bermond <dbermond at archlinux.org>
-# Contributor: saxonbeta <saxonbeta at gmail>
-# Contributor: Pierre Gueth <pierre.gueth at gmail>
-# Contributor: Daniel YC Lin <dlin.tw at gmail>
-# Contributor: Tim Huetz <tim at huetz biz>
-
-pkgname=libsvm
-pkgver=3.25
-pkgrel=2
-pkgdesc='A library for Support Vector Machines classification (includes binaries and bindings for python and java)'
-arch=('x86_64')
-url='https://www.csie.ntu.edu.tw/~cjlin/libsvm/'
-license=('BSD')
-depends=('gcc-libs')
-makedepends=('qt5-base' 'python')
-optdepends=('qt5-base: for Qt5 interface with svm-toy'
-            'python: for python modules and python CLI tools'
-            'gnuplot: for using svm-easy.py'
-            'java-runtime: for java bindings')
-source=("https://github.com/cjlin1/libsvm/archive/v${pkgver/./}/${pkgname}-${pkgver}.tar.gz"
-        '010-libsvm-fix-qt-headers-path.patch'
-        '020-libsvm-use-archlinux-flags.patch'
-        '030-libsvm-fix-tools-path.patch')
-sha256sums=('1f587ec0df6fd422dfe50f942f8836ac179b0723b768fe9d2fabdfd1601a0963'
-            '07bc50e50c3e34823e1669fec1be84a50fcea2307dcf33b00300135e08d2de4d'
-            '6891fcbedf246c6b73d43551ce2476678dc473cee45d12d9fcaf124a1aac0d92'
-            '17c54ef795209112f2e1c8f15aaf74bb0214681df09a8abca16b5bfb2506e193')
-
-prepare() {
-    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/010-libsvm-fix-qt-headers-path.patch"
-    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/020-libsvm-use-archlinux-flags.patch"
-    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/030-libsvm-fix-tools-path.patch"
-}
-
-build() {
-    make -C "${pkgname}-${pkgver/./}" lib all
-    make -C "${pkgname}-${pkgver/./}/svm-toy/qt"
-}
-
-package() {
-    cd "${pkgname}-${pkgver/./}"
-    
-    # binaries
-    install -D -m755 svm-{{predict,scale,train},toy/qt/svm-toy} -t "${pkgdir}/usr/bin"
-    
-    # library
-    install -D -m755 libsvm.so.* -t "${pkgdir}/usr/lib"
-    ln -s "$(find "${pkgdir}/usr/lib" -regex '.*libsvm.so.[0-9]*' -exec basename '{}' ';')" "${pkgdir}/usr/lib/libsvm.so"
-    
-    # header
-    install -D -m644 svm.h -t "${pkgdir}/usr/include/libsvm"
-    
-    # python modules
-    # NOTE: 'grid.py' can be used either as a python module or a CLI/tool
-    # https://github.com/cjlin1/libsvm/blob/v325/tools/README#L163-L164
-    local _pyver
-    _pyver="$(python -c 'import sys; print("%s.%s" %sys.version_info[0:2])')"
-    install -D -m644 python/libsvm/{{common,svm}util,svm,__init__}.py -t "${pkgdir}/usr/lib/python${_pyver}/site-packages/libsvm"
-    ln -s ../../../../bin/svm-grid.py "${pkgdir}/usr/lib/python${_pyver}/site-packages/libsvm/grid.py"
-    
-    # python CLI/tools
-    install -D -m755 tools/checkdata.py "${pkgdir}/usr/bin/svm-checkdata.py"
-    install -D -m755 tools/easy.py      "${pkgdir}/usr/bin/svm-easy.py"
-    install -D -m755 tools/grid.py      "${pkgdir}/usr/bin/svm-grid.py"
-    install -D -m755 tools/subset.py    "${pkgdir}/usr/bin/svm-subset.py"
-    
-    # java
-    install -D -m644 java/libsvm.jar -t "${pkgdir}/usr/share/java"
-    
-    # license
-    install -D -m644 COPYRIGHT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
-}

Copied: libsvm/repos/community-x86_64/PKGBUILD (from rev 1072706, libsvm/trunk/PKGBUILD)
===================================================================
--- PKGBUILD	                        (rev 0)
+++ PKGBUILD	2021-12-14 02:46:56 UTC (rev 1072707)
@@ -0,0 +1,72 @@
+# Maintainer : Daniel Bermond <dbermond at archlinux.org>
+# Contributor: saxonbeta <saxonbeta at gmail>
+# Contributor: Pierre Gueth <pierre.gueth at gmail>
+# Contributor: Daniel YC Lin <dlin.tw at gmail>
+# Contributor: Tim Huetz <tim at huetz biz>
+
+pkgname=libsvm
+pkgver=3.25
+pkgrel=3
+pkgdesc='A library for Support Vector Machines classification (includes binaries and bindings for python and java)'
+arch=('x86_64')
+url='https://www.csie.ntu.edu.tw/~cjlin/libsvm/'
+license=('BSD')
+depends=('gcc-libs')
+makedepends=('qt5-base' 'python')
+optdepends=('qt5-base: for Qt5 interface with svm-toy'
+            'python: for python modules and python CLI tools'
+            'gnuplot: for using svm-easy.py'
+            'java-runtime: for java bindings')
+source=("https://github.com/cjlin1/libsvm/archive/v${pkgver/./}/${pkgname}-${pkgver}.tar.gz"
+        '010-libsvm-fix-qt-headers-path.patch'
+        '020-libsvm-use-archlinux-flags.patch'
+        '030-libsvm-fix-tools-path.patch')
+sha256sums=('1f587ec0df6fd422dfe50f942f8836ac179b0723b768fe9d2fabdfd1601a0963'
+            '07bc50e50c3e34823e1669fec1be84a50fcea2307dcf33b00300135e08d2de4d'
+            '6891fcbedf246c6b73d43551ce2476678dc473cee45d12d9fcaf124a1aac0d92'
+            '67f57236a6c4b09f051e74f8cb1ef5dbc9b5de3fdbb2b1a6ff86a07db0dd5fb9')
+
+prepare() {
+    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/010-libsvm-fix-qt-headers-path.patch"
+    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/020-libsvm-use-archlinux-flags.patch"
+    patch -d "${pkgname}-${pkgver/./}" -Np1 -i "${srcdir}/030-libsvm-fix-tools-path.patch"
+}
+
+build() {
+    make -C "${pkgname}-${pkgver/./}" lib all
+    make -C "${pkgname}-${pkgver/./}/svm-toy/qt"
+}
+
+package() {
+    cd "${pkgname}-${pkgver/./}"
+    
+    # binaries
+    install -D -m755 svm-{{predict,scale,train},toy/qt/svm-toy} -t "${pkgdir}/usr/bin"
+    
+    # library
+    install -D -m755 libsvm.so.* -t "${pkgdir}/usr/lib"
+    ln -s "$(find "${pkgdir}/usr/lib" -regex '.*libsvm.so.[0-9]*' -exec basename '{}' ';')" "${pkgdir}/usr/lib/libsvm.so"
+    
+    # header
+    install -D -m644 svm.h -t "${pkgdir}/usr/include/libsvm"
+    
+    # python modules
+    # NOTE: 'grid.py' can be used either as a python module or a CLI/tool
+    # https://github.com/cjlin1/libsvm/blob/v325/tools/README#L163-L164
+    local _pyver
+    _pyver="$(python -c 'import sys; print("%s.%s" %sys.version_info[0:2])')"
+    install -D -m644 python/libsvm/{{common,svm}util,svm,__init__}.py -t "${pkgdir}/usr/lib/python${_pyver}/site-packages/libsvm"
+    ln -s ../../../../bin/svm-grid.py "${pkgdir}/usr/lib/python${_pyver}/site-packages/libsvm/grid.py"
+    
+    # python CLI/tools
+    install -D -m755 tools/checkdata.py "${pkgdir}/usr/bin/svm-checkdata.py"
+    install -D -m755 tools/easy.py      "${pkgdir}/usr/bin/svm-easy.py"
+    install -D -m755 tools/grid.py      "${pkgdir}/usr/bin/svm-grid.py"
+    install -D -m755 tools/subset.py    "${pkgdir}/usr/bin/svm-subset.py"
+    
+    # java
+    install -D -m644 java/libsvm.jar -t "${pkgdir}/usr/share/java"
+    
+    # license
+    install -D -m644 COPYRIGHT "${pkgdir}/usr/share/licenses/${pkgname}/LICENSE"
+}



More information about the arch-commits mailing list