New package: zinnia-0.06
This commit is contained in:
parent
4acece4614
commit
9194c5e28d
6 changed files with 96 additions and 0 deletions
|
@ -2895,3 +2895,4 @@ liblsmash.so.2 liblsmash-2.9.1_1
|
|||
libgnustep-base.so.1.25 gnustep-base-1.25.0_1
|
||||
libtermbox.so.1 termbox-1.1.0_1
|
||||
libmysofa.so.0 libmysofa-0.6_1
|
||||
libzinnia.so.0 libzinnia-0.06_1
|
||||
|
|
1
srcpkgs/libzinnia
Symbolic link
1
srcpkgs/libzinnia
Symbolic link
|
@ -0,0 +1 @@
|
|||
zinnia
|
1
srcpkgs/libzinnia-devel
Symbolic link
1
srcpkgs/libzinnia-devel
Symbolic link
|
@ -0,0 +1 @@
|
|||
zinnia
|
|
@ -0,0 +1,39 @@
|
|||
From b49a0187e74ff619f28fb20e2b5ecfec1d437d6f Mon Sep 17 00:00:00 2001
|
||||
From: Yohei Yukawa <yukawa@google.com>
|
||||
Date: Sat, 5 Sep 2015 02:06:05 -0700
|
||||
Subject: [PATCH] Fix compile error of std::make_pair in C++11
|
||||
|
||||
std::make_pair is not designed to be used with explicit type
|
||||
parameters. In practice doing that can result in compile error
|
||||
with Clang 3.4 on Ubuntu 14.04 when C++11 is enabled.
|
||||
|
||||
This CL removes explicit type parameters so that Zinnia can be
|
||||
built even if C++11 is enabled.
|
||||
---
|
||||
AUTHORS | 1 +
|
||||
trainer.cpp | 2 +-
|
||||
2 files changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/AUTHORS b/AUTHORS
|
||||
index a44e82c..fa52d6a 100644
|
||||
--- AUTHORS
|
||||
+++ AUTHORS
|
||||
@@ -1 +1,2 @@
|
||||
Taku Kudo <taku@chasen.org>
|
||||
+Google Inc. <*@google.com>
|
||||
diff --git a/trainer.cpp b/trainer.cpp
|
||||
index a889bc7..84230b0 100644
|
||||
--- trainer.cpp
|
||||
+++ trainer.cpp
|
||||
@@ -104,7 +104,7 @@ class TrainerImpl: public Trainer {
|
||||
if (!fn) {
|
||||
return false;
|
||||
}
|
||||
- x_.push_back(std::make_pair<std::string, FeatureNode *>(y, fn));
|
||||
+ x_.push_back(std::make_pair(y, fn));
|
||||
return true;
|
||||
}
|
||||
|
||||
--
|
||||
2.14.1
|
||||
|
12
srcpkgs/zinnia/patches/minimum-distance-precision.patch
Normal file
12
srcpkgs/zinnia/patches/minimum-distance-precision.patch
Normal file
|
@ -0,0 +1,12 @@
|
|||
--- feature.cpp
|
||||
+++ feature.cpp
|
||||
@@ -42,7 +42,8 @@ float minimum_distance(const Node *first, const Node *last,
|
||||
|
||||
const float a = last->x - first->x;
|
||||
const float b = last->y - first->y;
|
||||
- const float c = last->y * first->x - last->x * first->y;
|
||||
+ const float c = static_cast<double>(last->y * first->x)
|
||||
+ - static_cast<double>(last->x * first->y);
|
||||
|
||||
float max = -1.0;
|
||||
for (const Node *n = first; n != last; ++n) {
|
42
srcpkgs/zinnia/template
Normal file
42
srcpkgs/zinnia/template
Normal file
|
@ -0,0 +1,42 @@
|
|||
# Template file for 'zinnia'
|
||||
pkgname=zinnia
|
||||
version=0.06
|
||||
revision=1
|
||||
short_desc="OCR system for hand-written input"
|
||||
maintainer="Matthias von Faber <mvf@gmx.eu>"
|
||||
homepage="http://taku910.github.io/zinnia/"
|
||||
license="2-clause-BSD"
|
||||
build_style=gnu-configure
|
||||
hostmakedepends="libtool pkg-config"
|
||||
makedepends="libtool pkg-config"
|
||||
distfiles="${SOURCEFORGE_SITE}/${pkgname}/${pkgname}/${version}/${pkgname}-${version}.tar.gz"
|
||||
checksum=ece3af93f937282971634fd81d3e997f848e8cfa958220e26a4564ca064ac20b
|
||||
|
||||
post_install() {
|
||||
vlicense COPYING
|
||||
}
|
||||
|
||||
libzinnia_package() {
|
||||
short_desc+=" - runtime library"
|
||||
pkg_install() {
|
||||
vmove "usr/lib/*.so.*"
|
||||
}
|
||||
}
|
||||
|
||||
pre_build() {
|
||||
# Force flags from environment
|
||||
sed -i -e 's|^CFLAGS\b|#CFLAGS|' \
|
||||
-e 's|^CXXFLAGS\b|#CXXFLAGS|' \
|
||||
-e 's|^LDFLAGS\b|#LDFLAGS|' Makefile
|
||||
}
|
||||
|
||||
libzinnia-devel_package() {
|
||||
depends="lib${sourcepkg}>=${version}_${revision}"
|
||||
short_desc+=" - development files"
|
||||
pkg_install() {
|
||||
vmove usr/include
|
||||
vmove usr/lib/pkgconfig
|
||||
vmove "usr/lib/*.a"
|
||||
vmove "usr/lib/*.so"
|
||||
}
|
||||
}
|
Loading…
Reference in a new issue