Haru: Added patches
Added patches created from upstream: Fix unitialized ptr error Add missing LICENSE file Signed-off-by: Nathan Owens <ndowens04@gmail.com>
This commit is contained in:
parent
0ea1b9cf0d
commit
cd5094e3e2
3 changed files with 98 additions and 3 deletions
40
srcpkgs/Haru/patches/Add-license.patch
Normal file
40
srcpkgs/Haru/patches/Add-license.patch
Normal file
|
@ -0,0 +1,40 @@
|
|||
From 24443b76f4daf74c21307044e81b4942bd4e586a Mon Sep 17 00:00:00 2001
|
||||
From: Maciej Klemarczyk <m.klemarczyk+git@live.com>
|
||||
Date: Sun, 28 Jun 2015 12:05:05 +0200
|
||||
Subject: [PATCH 4/4] Missing LICENSE file was created
|
||||
|
||||
File was created based on license provided by README file.
|
||||
---
|
||||
LICENCE | 20 ++++++++++++++++++++
|
||||
1 file changed, 20 insertions(+)
|
||||
create mode 100644 LICENSE
|
||||
|
||||
diff --git LICENSE LICENSE
|
||||
new file mode 100644
|
||||
index 0000000..bdf271e
|
||||
--- /dev/null
|
||||
+++ LICENSE
|
||||
@@ -0,0 +1,20 @@
|
||||
+
|
||||
+Copyright (C) 1999-2006 Takeshi Kanno
|
||||
+Copyright (C) 2007-2009 Antony Dovgal
|
||||
+
|
||||
+This software is provided 'as-is', without any express or implied warranty.
|
||||
+
|
||||
+In no event will the authors be held liable for any damages arising from the
|
||||
+use of this software.
|
||||
+
|
||||
+Permission is granted to anyone to use this software for any purpose,including
|
||||
+commercial applications, and to alter it and redistribute it freely, subject
|
||||
+to the following restrictions:
|
||||
+
|
||||
+ 1. The origin of this software must not be misrepresented; you must not claim
|
||||
+ that you wrote the original software. If you use this software in a
|
||||
+ product, an acknowledgment in the product documentation would be
|
||||
+ appreciated but is not required.
|
||||
+ 2. Altered source versions must be plainly marked as such, and must not be
|
||||
+ misrepresented as being the original software.
|
||||
+ 3. This notice may not be removed or altered from any source distribution.
|
||||
--
|
||||
2.24.0
|
||||
|
55
srcpkgs/Haru/patches/unitialized-ptr_error.patch
Normal file
55
srcpkgs/Haru/patches/unitialized-ptr_error.patch
Normal file
|
@ -0,0 +1,55 @@
|
|||
From d2fd3a47686fe8f1c1263d5d8190b2ceb2f4327e Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Viktor=20Szak=C3=A1ts?= <vszakats@users.noreply.github.com>
|
||||
Date: Sat, 5 Oct 2013 00:51:03 +0200
|
||||
Subject: [PATCH 1/4] fixed potentially uninitialized ptr error
|
||||
|
||||
also deleted two line ending spaces
|
||||
---
|
||||
src/hpdf_image_png.c | 8 ++++----
|
||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
||||
|
||||
diff --git src/hpdf_image_png.c src/hpdf_image_png.c
|
||||
index 3a35f5c..3f20a77 100644
|
||||
--- src/hpdf_image_png.c
|
||||
+++ src/hpdf_image_png.c
|
||||
@@ -280,8 +280,8 @@ ReadTransparentPngData (HPDF_Dict image,
|
||||
case PNG_COLOR_TYPE_RGB_ALPHA:
|
||||
row_len = 3 * width * sizeof(png_byte);
|
||||
for (j = 0; j < height; j++) {
|
||||
+ row = row_ptr[j];
|
||||
for (i = 0; i < width; i++) {
|
||||
- row = row_ptr[j];
|
||||
memmove(row + (3 * i), row + (4*i), 3);
|
||||
smask_data[width * j + i] = row[4 * i + 3];
|
||||
}
|
||||
@@ -295,8 +295,8 @@ ReadTransparentPngData (HPDF_Dict image,
|
||||
case PNG_COLOR_TYPE_GRAY_ALPHA:
|
||||
row_len = width * sizeof(png_byte);
|
||||
for (j = 0; j < height; j++) {
|
||||
+ row = row_ptr[j];
|
||||
for (i = 0; i < width; i++) {
|
||||
- row = row_ptr[j];
|
||||
row[i] = row[2 * i];
|
||||
smask_data[width * j + i] = row[2 * i + 1];
|
||||
}
|
||||
@@ -474,7 +474,7 @@ LoadPngData (HPDF_Dict image,
|
||||
HPDF_Dict smask;
|
||||
png_bytep smask_data;
|
||||
|
||||
- if (!png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ||
|
||||
+ if (!png_get_valid(png_ptr, info_ptr, PNG_INFO_tRNS) ||
|
||||
!png_get_tRNS(png_ptr, info_ptr, &trans, &num_trans, NULL)) {
|
||||
goto no_transparent_color_in_palette;
|
||||
}
|
||||
@@ -534,7 +534,7 @@ LoadPngData (HPDF_Dict image,
|
||||
|
||||
no_transparent_color_in_palette:
|
||||
|
||||
- /* read images with alpha channel right away
|
||||
+ /* read images with alpha channel right away
|
||||
we have to do this because image transparent mask must be added to the Xref */
|
||||
if (xref && PNG_COLOR_MASK_ALPHA & color_type) {
|
||||
HPDF_Dict smask;
|
||||
--
|
||||
2.24.0
|
||||
|
|
@ -1,7 +1,8 @@
|
|||
# Template file for 'Haru'
|
||||
pkgname=Haru
|
||||
version=2.3.0
|
||||
revision=1
|
||||
revision=2
|
||||
wrksrc="libharu-RELEASE_${version//./_}"
|
||||
build_style=cmake
|
||||
makedepends="zlib-devel libpng-devel"
|
||||
short_desc="Free, cross platform, open source library for generating PDF files"
|
||||
|
@ -9,11 +10,10 @@ maintainer="Florian Eich <flrn@nrmncr.net>"
|
|||
license="ZLIB/LIBPNG"
|
||||
homepage="http://libharu.org/"
|
||||
distfiles="https://github.com/libharu/libharu/archive/RELEASE_${version//./_}.tar.gz"
|
||||
wrksrc="libharu-RELEASE_${version//./_}"
|
||||
checksum=8f9e68cc5d5f7d53d1bc61a1ed876add1faf4f91070dbc360d8b259f46d9a4d2
|
||||
|
||||
post_install() {
|
||||
vlicense README LICENSE
|
||||
vlicense LICENSE
|
||||
}
|
||||
|
||||
Haru-devel_package() {
|
||||
|
|
Loading…
Reference in a new issue