New package: nufraw-0.43.3
Co-authored-by: triallax <triallax@tutanota.com>
This commit is contained in:
parent
09207b318b
commit
d16222b867
13 changed files with 138 additions and 144 deletions
1
srcpkgs/nufraw-gimp
Symbolic link
1
srcpkgs/nufraw-gimp
Symbolic link
|
@ -0,0 +1 @@
|
|||
nufraw
|
20
srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
Normal file
20
srcpkgs/nufraw/patches/0001-nufraw-glib-2.70.patch
Normal file
|
@ -0,0 +1,20 @@
|
|||
diff -ru nufraw/uf_glib.h nufraw/uf_glib.h
|
||||
--- nufraw/uf_glib.h 2022-02-23 09:03:44.700472919 +0100
|
||||
+++ nufraw/uf_glib.h 2022-02-23 09:04:50.260308805 +0100
|
||||
@@ -13,13 +13,13 @@
|
||||
#ifndef _UF_GLIB_H
|
||||
#define _UF_GLIB_H
|
||||
|
||||
+#include <glib.h>
|
||||
+#include <glib/gstdio.h>
|
||||
+
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
-#include <glib.h>
|
||||
-#include <glib/gstdio.h>
|
||||
-
|
||||
// g_win32_locale_filename_from_utf8 is needed only on win32
|
||||
#ifdef _WIN32
|
||||
#define uf_win32_locale_filename_from_utf8(__some_string__) \
|
59
srcpkgs/nufraw/patches/exiv-0.28.x.diff
Normal file
59
srcpkgs/nufraw/patches/exiv-0.28.x.diff
Normal file
|
@ -0,0 +1,59 @@
|
|||
Patch taken from AUR package: https://aur.archlinux.org/cgit/aur.git/tree/exiv2-error.patch?h=nufraw&id=29e467f2c297fcd0f36548642d6d2cab6428d08f
|
||||
diff --git a/nufraw_exiv2.cc b/nufraw_exiv2.cc
|
||||
index 2de4cc3..45aea87 100644
|
||||
--- a/nufraw_exiv2.cc
|
||||
+++ b/nufraw_exiv2.cc
|
||||
@@ -54,7 +54,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
|
||||
uf->inputExifBuf = NULL;
|
||||
uf->inputExifBufLen = 0;
|
||||
|
||||
- Exiv2::Image::AutoPtr image;
|
||||
+ Exiv2::Image::UniquePtr image;
|
||||
if (uf->unzippedBuf != NULL) {
|
||||
image = Exiv2::ImageFactory::open(
|
||||
(const Exiv2::byte*)uf->unzippedBuf, uf->unzippedBufLen);
|
||||
@@ -135,7 +135,7 @@ extern "C" int nufraw_exif_read_input(nufraw_data *uf)
|
||||
nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
|
||||
|
||||
return NUFRAW_SUCCESS;
|
||||
- } catch (Exiv2::AnyError& e) {
|
||||
+ } catch (Exiv2::Error& e) {
|
||||
std::cerr.rdbuf(savecerr);
|
||||
std::string s(e.what());
|
||||
nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
|
||||
@@ -156,7 +156,7 @@ static Exiv2::ExifData nufraw_prepare_exifdata(nufraw_data *uf)
|
||||
if ((pos = exifData.findKey(Exiv2::ExifKey("Exif.Image.Orientation")))
|
||||
!= exifData.end()) {
|
||||
nufraw_message(NUFRAW_SET_LOG, "Resetting %s from '%d' to '1'\n",
|
||||
- pos->key().c_str(), pos->value().toLong());
|
||||
+ pos->key().c_str(), pos->value().toInt64());
|
||||
pos->setValue("1"); /* 1 = Normal orientation */
|
||||
}
|
||||
}
|
||||
@@ -327,7 +327,7 @@ extern "C" int nufraw_exif_prepare_output(nufraw_data *uf)
|
||||
nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
|
||||
|
||||
return NUFRAW_SUCCESS;
|
||||
- } catch (Exiv2::AnyError& e) {
|
||||
+ } catch (Exiv2::Error& e) {
|
||||
std::cerr.rdbuf(savecerr);
|
||||
std::string s(e.what());
|
||||
nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
|
||||
@@ -347,7 +347,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
|
||||
|
||||
char *filename =
|
||||
uf_win32_locale_filename_from_utf8(uf->conf->outputFilename);
|
||||
- Exiv2::Image::AutoPtr image = Exiv2::ImageFactory::open(filename);
|
||||
+ Exiv2::Image::UniquePtr image = Exiv2::ImageFactory::open(filename);
|
||||
uf_win32_locale_filename_free(filename);
|
||||
assert(image.get() != 0);
|
||||
|
||||
@@ -367,7 +367,7 @@ extern "C" int nufraw_exif_write(nufraw_data *uf)
|
||||
nufraw_message(NUFRAW_SET_LOG, "%s\n", stderror.str().c_str());
|
||||
|
||||
return NUFRAW_SUCCESS;
|
||||
- } catch (Exiv2::AnyError& e) {
|
||||
+ } catch (Exiv2::Error& e) {
|
||||
std::cerr.rdbuf(savecerr);
|
||||
std::string s(e.what());
|
||||
nufraw_message(NUFRAW_SET_WARNING, "%s\n", s.c_str());
|
56
srcpkgs/nufraw/template
Normal file
56
srcpkgs/nufraw/template
Normal file
|
@ -0,0 +1,56 @@
|
|||
# Template file for 'nufraw'
|
||||
pkgname=nufraw
|
||||
version=0.43.3
|
||||
revision=1
|
||||
_ver="${version%.*}-${version##*.}"
|
||||
build_style=gnu-configure
|
||||
configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
|
||||
--enable-extras"
|
||||
hostmakedepends="pkg-config automake libtool glib-devel"
|
||||
# libgexiv2-devel is only here to fix build order, remove on next template
|
||||
# change
|
||||
makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel
|
||||
lensfun-devel jasper-devel libgexiv2-devel"
|
||||
depends="desktop-file-utils"
|
||||
short_desc="Utility to read and manipulate raw images from digital cameras"
|
||||
maintainer="John <me@johnnynator.dev>"
|
||||
license="GPL-2.0-or-later"
|
||||
homepage="https://sourceforge.net/projects/nufraw/"
|
||||
distfiles="${SOURCEFORGE_SITE}/nufraw/nufraw-${_ver}.tar.gz"
|
||||
checksum=2c7dcc1590993ec267b3112562b2433010d6f94f6acc6506c76aa29cf8c6c32c
|
||||
|
||||
case "$XBPS_TARGET_MACHINE" in
|
||||
armv[67]l* | aarch64*)
|
||||
makedepends+=" libgomp-devel"
|
||||
make_build_args="CXXFLAGS+=-fsigned-char LDFLAGS+=-fopenmp"
|
||||
;;
|
||||
esac
|
||||
|
||||
pre_configure() {
|
||||
autoreconf -fi
|
||||
}
|
||||
|
||||
pre_build() {
|
||||
mv nufraw.desktop{.desktop,}
|
||||
chmod +x generate_schemas.sh
|
||||
}
|
||||
|
||||
nufraw-gimp_package() {
|
||||
depends="${sourcepkg}>=${version}_${revision}"
|
||||
short_desc+=" - gimp plugin"
|
||||
pkg_install() {
|
||||
vmove usr/lib/gimp
|
||||
}
|
||||
}
|
||||
|
||||
ufraw_package() {
|
||||
depends="${sourcepkg}>=${version}_${revision}"
|
||||
build_style=meta
|
||||
short_desc+=" (transitional dummy package)"
|
||||
}
|
||||
|
||||
ufraw-gimp_package() {
|
||||
depends="nufraw-gimp>=${version}_${revision}"
|
||||
build_style=meta
|
||||
short_desc+=" - gimp plugin (transitional dummy package)"
|
||||
}
|
1
srcpkgs/ufraw
Symbolic link
1
srcpkgs/ufraw
Symbolic link
|
@ -0,0 +1 @@
|
|||
nufraw
|
|
@ -1 +1 @@
|
|||
ufraw
|
||||
nufraw
|
|
@ -1,12 +0,0 @@
|
|||
Don't use gimp-remote since gimp 2.4 already includes gimp-remote functionality
|
||||
--- a/ufraw_conf.c
|
||||
+++ b/ufraw_conf.c
|
||||
@@ -137,7 +137,7 @@
|
||||
#elif HAVE_GIMP_2_4
|
||||
"gimp", /* remoteGimpCommand */
|
||||
#else
|
||||
- "gimp-remote", /* remoteGimpCommand */
|
||||
+ "gimp", /* remoteGimpCommand */
|
||||
#endif
|
||||
|
||||
/* EXIF data */
|
|
@ -1,11 +0,0 @@
|
|||
--- a/dcraw.cc 2015-06-16 05:58:38.000000000 +0200
|
||||
+++ b/dcraw.cc 2018-02-04 14:46:54.489951076 +0100
|
||||
@@ -9242,7 +9242,7 @@
|
||||
if (make[0] == 'O') {
|
||||
i = find_green (12, 32, 1188864, 3576832);
|
||||
c = find_green (12, 32, 2383920, 2387016);
|
||||
- if (abs(i) < abs(c)) {
|
||||
+ if (abs((int)i) < abs((int)c)) {
|
||||
SWAP(i,c);
|
||||
load_flags = 24;
|
||||
}
|
|
@ -1,14 +0,0 @@
|
|||
Source: written by John Paul Adrian Glaubitz for Debian
|
||||
Upstream: https://sourceforge.net/p/ufraw/bugs/417
|
||||
Reason: fixes a compilation failure on arm architectures
|
||||
--- a/dcraw.cc
|
||||
+++ b/dcraw.cc
|
||||
@@ -2285,7 +2285,7 @@ void CLASS quicktake_100_load_raw()
|
||||
|
||||
void CLASS kodak_radc_load_raw()
|
||||
{
|
||||
- static const char src[] = {
|
||||
+ static const signed char src[] = {
|
||||
1,1, 2,3, 3,4, 4,2, 5,7, 6,5, 7,6, 7,8,
|
||||
1,0, 2,1, 3,3, 4,4, 5,2, 6,7, 7,6, 8,5, 8,8,
|
||||
2,1, 2,3, 3,0, 3,2, 3,4, 4,6, 5,5, 6,7, 6,8,
|
|
@ -1,25 +0,0 @@
|
|||
--- a/ufraw_exiv2.cc 2015-06-16 05:58:38.000000000 +0200
|
||||
+++ b/ufraw_exiv2.cc 2018-12-29 22:51:23.291894430 +0100
|
||||
@@ -15,9 +15,7 @@
|
||||
#include "ufraw.h"
|
||||
|
||||
#ifdef HAVE_EXIV2
|
||||
-#include <exiv2/image.hpp>
|
||||
-#include <exiv2/easyaccess.hpp>
|
||||
-#include <exiv2/exif.hpp>
|
||||
+#include <exiv2/exiv2.hpp>
|
||||
#include <sstream>
|
||||
#include <cassert>
|
||||
|
||||
@@ -67,7 +65,11 @@
|
||||
if (exifData.empty()) {
|
||||
std::string error(uf->filename);
|
||||
error += ": No Exif data found in the file";
|
||||
+#if EXIV2_TEST_VERSION(0,27,0)
|
||||
+ throw Exiv2::Error(Exiv2::kerErrorMessage, error);
|
||||
+#else
|
||||
throw Exiv2::Error(1, error);
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* List of tag names taken from exiv2's printSummary() in actions.cpp */
|
|
@ -1,30 +0,0 @@
|
|||
From c56f8be3caf1cf3d9a5c80597bdbaf1325faacc0 Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?S=C3=A9rgio=20M=2E=20Basto?= <sergio@serjux.com>
|
||||
Date: Tue, 13 Apr 2021 23:45:39 +0100
|
||||
Subject: [PATCH] Fix build against glib-2.68 fixes #10
|
||||
|
||||
---
|
||||
uf_glib.h | 6 +++---
|
||||
1 file changed, 3 insertions(+), 3 deletions(-)
|
||||
|
||||
diff --git a/uf_glib.h b/uf_glib.h
|
||||
index 21c10b19..56cd6971 100644
|
||||
--- a/uf_glib.h
|
||||
+++ b/uf_glib.h
|
||||
@@ -13,13 +13,13 @@
|
||||
#ifndef _UF_GLIB_H
|
||||
#define _UF_GLIB_H
|
||||
|
||||
+#include <glib.h>
|
||||
+#include <glib/gstdio.h>
|
||||
+
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
-#include <glib.h>
|
||||
-#include <glib/gstdio.h>
|
||||
-
|
||||
// g_win32_locale_filename_from_utf8 is needed only on win32
|
||||
#ifdef _WIN32
|
||||
#define uf_win32_locale_filename_from_utf8(__some_string__) \
|
|
@ -1,13 +0,0 @@
|
|||
ufraw_exiv2.cc:343:10: note: 'std::cerr' is defined in header '<iostream>'
|
||||
ufraw_exiv2.cc:365:14: error: 'cerr' is not a member of 'std'
|
||||
|
||||
--- a/ufraw_exiv2.cc
|
||||
+++ b/ufraw_exiv2.cc
|
||||
@@ -17,6 +17,7 @@
|
||||
#ifdef HAVE_EXIV2
|
||||
#include <exiv2/exiv2.hpp>
|
||||
#include <sstream>
|
||||
+#include <iostream>
|
||||
#include <cassert>
|
||||
|
||||
/*
|
|
@ -1,38 +0,0 @@
|
|||
# Template file for 'ufraw'
|
||||
pkgname=ufraw
|
||||
version=0.22
|
||||
revision=5
|
||||
build_style=gnu-configure
|
||||
configure_args="--enable-contrast --enable-mime --enable-openmp --with-gimp
|
||||
$(vopt_enable extras)"
|
||||
hostmakedepends="pkg-config dcraw gettext"
|
||||
makedepends="exiv2-devel gimp-devel glib-devel gtkimageview-devel lcms2-devel lensfun-devel
|
||||
jasper-devel"
|
||||
depends="desktop-file-utils"
|
||||
short_desc="Utility to read and manipulate raw images from digital cameras"
|
||||
maintainer="John <me@johnnynator.dev>"
|
||||
license="GPL-2.0-or-later"
|
||||
homepage="http://ufraw.sourceforge.net/"
|
||||
distfiles="${SOURCEFORGE_SITE}/ufraw/ufraw/ufraw-${version}/ufraw-${version}.tar.gz"
|
||||
checksum=f7abd28ce587db2a74b4c54149bd8a2523a7ddc09bedf4f923246ff0ae09a25e
|
||||
|
||||
build_options="extras"
|
||||
|
||||
post_patch() {
|
||||
vsed -e 's/default(none)//g' \
|
||||
-i dcraw_indi.c \
|
||||
-i dcraw_api.cc \
|
||||
-i ufraw_ufraw.c \
|
||||
-i ufraw_developer.c
|
||||
vsed -i -e '/DATADIRNAME=/s/=.*/=share/' configure
|
||||
vsed -i -e "s,^localedir =.*,localedir = /usr/share/locale," \
|
||||
po/Makefile.in.in
|
||||
}
|
||||
|
||||
ufraw-gimp_package() {
|
||||
depends="${sourcepkg}>=${version}_${revision}"
|
||||
short_desc+=" - gimp plugin"
|
||||
pkg_install() {
|
||||
vmove usr/lib/gimp
|
||||
}
|
||||
}
|
Loading…
Add table
Reference in a new issue