summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'media-libs/libemf')
-rw-r--r--media-libs/libemf/Manifest2
-rw-r--r--media-libs/libemf/files/libemf-1.0.4-amd64-alpha.patch95
-rw-r--r--media-libs/libemf/libemf-1.0.4-r1.ebuild38
-rw-r--r--media-libs/libemf/libemf-1.0.7.ebuild36
-rw-r--r--media-libs/libemf/metadata.xml10
5 files changed, 181 insertions, 0 deletions
diff --git a/media-libs/libemf/Manifest b/media-libs/libemf/Manifest
new file mode 100644
index 000000000000..b7daa58ea585
--- /dev/null
+++ b/media-libs/libemf/Manifest
@@ -0,0 +1,2 @@
+DIST libEMF-1.0.4.tar.gz 818060 SHA256 71f6a72ec7b9693217da2b366ac39655803b5f07d4600d7636e827f3b16c66ff SHA512 8abd6081e79e6045b0a4a1575fbcc19921beeefb22036164ed906a35e4dbc67b6959899acf46bb5db5996ae07cf38aaecf8eb62dd6bf5f528200a4d20b13db55 WHIRLPOOL bf71d9812f88ae81e3a6f5436c24de8daf7bee3d0d60e6a9c4743c3aeb8a1a99c1029be4c688c0d9f11204ac7bf62d90be87cb435b2c9075d94bc5403e166cc1
+DIST libEMF-1.0.7.tar.gz 908973 SHA256 9f2fd8bb84e345978c7fc45a39e06fc6a44fee867a91ebe83433d3a34348fd21 SHA512 eff5c46a6e1008d8f581fda59355faa608a825e4832c54dbb074bf20caeee5b038ce18ed3a13181de04bd0601837db7f5c5a0913eb1b8301100dbc26a9ee5888 WHIRLPOOL 7bf19d95b7a679a1c4e3a9a1075c94f04cf40a46bfec3e7308fcbf3d1ce3810c900706c35f2fe42209c5514d8c8ccb76343bd0985bcec6cdc37f7f34af6b3322
diff --git a/media-libs/libemf/files/libemf-1.0.4-amd64-alpha.patch b/media-libs/libemf/files/libemf-1.0.4-amd64-alpha.patch
new file mode 100644
index 000000000000..6f809a957e76
--- /dev/null
+++ b/media-libs/libemf/files/libemf-1.0.4-amd64-alpha.patch
@@ -0,0 +1,95 @@
+--- a/include/libEMF/wine/winbase.h
++++ b/include/libEMF/wine/winbase.h
+@@ -1802,6 +1802,7 @@ LONG WINAPI InterlockedIncrement(PLONG);
+ VOID WINAPI SetLastError(DWORD);
+ #endif /* __i386__ && __GNUC__ */
+
++#if 0
+ /* FIXME: should handle platforms where sizeof(void*) != sizeof(long) */
+ static inline PVOID WINAPI InterlockedCompareExchangePointer( PVOID *dest, PVOID xchg, PVOID compare )
+ {
+@@ -1812,6 +1813,7 @@ static inline PVOID WINAPI InterlockedExchangePointer( PVOID *dest, PVOID val )
+ {
+ return (PVOID)InterlockedExchange( (PLONG)dest, (LONG)val );
+ }
++#endif
+
+ #ifdef __WINE__
+ #define GetCurrentProcess() ((HANDLE)0xffffffff)
+--- a/include/libEMF/wine/winnt.h
++++ b/include/libEMF/wine/winnt.h
+@@ -29,10 +29,14 @@
+
+ /* Architecture dependent settings. */
+ /* These are hardcoded to avoid dependencies on config.h in Winelib apps. */
+-#if defined(__i386__)
++#if defined(__i386__) || defined(__x86_64__)
+ # undef WORDS_BIGENDIAN
+ # undef BITFIELDS_BIGENDIAN
+ # define ALLOW_UNALIGNED_ACCESS
++#elif defined(__alpha__)
++# undef WORDS_BIGENDIAN
++# undef BITFIELDS_BIGENDIAN
++# undef ALLOW_UNALIGNED_ACCESS
+ #elif defined(__sparc__)
+ # define WORDS_BIGENDIAN
+ # define BITFIELDS_BIGENDIAN
+@@ -222,8 +226,13 @@ typedef unsigned short USHORT, *PUSHORT, *LPUSHORT;
+ typedef unsigned short WORD, *PWORD, *LPWORD;
+ typedef int INT, *PINT, *LPINT;
+ typedef unsigned int UINT, *PUINT, *LPUINT;
++#if defined(_LP64) || defined(__alpha__)
++typedef unsigned int DWORD, *PDWORD, *LPDWORD;
++typedef unsigned int ULONG, *PULONG, *LPULONG;
++#else
+ typedef unsigned long DWORD, *PDWORD, *LPDWORD;
+ typedef unsigned long ULONG, *PULONG, *LPULONG;
++#endif
+ typedef float FLOAT, *PFLOAT, *LPFLOAT;
+ typedef double DOUBLE, *PDOUBLE, *LPDOUBLE;
+ typedef double DATE;
+@@ -263,7 +272,11 @@ typedef VOID *PVOID, *LPVOID;
+ typedef BYTE BOOLEAN, *PBOOLEAN;
+ typedef char CHAR, *PCHAR;
+ typedef short SHORT, *PSHORT;
++#if defined(_LP64) || defined(__alpha__)
++typedef int LONG, *PLONG, *LPLONG;
++#else
+ typedef long LONG, *PLONG, *LPLONG;
++#endif
+
+ /* Some systems might have wchar_t, but we really need 16 bit characters */
+ #ifndef WINE_WCHAR_DEFINED
+@@ -652,8 +665,13 @@ typedef CONTEXT86 CONTEXT;
+
+ #endif /* __i386__ */
+
++#ifdef __x86_64__
++#define CONTEXT_FULL 1
++typedef struct _CONTEXT CONTEXT;
++#endif
++
+ /* Alpha context definitions */
+-#ifdef _ALPHA_
++#if defined(__alpha__)
+
+ #define CONTEXT_ALPHA 0x00020000
+
+--- a/libemf/libemf.h
++++ b/libemf/libemf.h
+@@ -306,6 +306,7 @@ namespace EMF {
+ fread( &word, sizeof(INT16), 1, fp_ );
+ return *this;
+ }
++#if !(defined(_LP64) || defined(__alpha__))
+ /*!
+ * Output a double word (long) to the stream (swabbed).
+ * \param word word (long) to output.
+@@ -374,6 +375,7 @@ namespace EMF {
+ fread( &long_, sizeof(LONG), 1, fp_ );
+ return *this;
+ }
++#endif
+ /*!
+ * Output a (long) int to the stream (swabbed).
+ * \param int_ (long) int to output.
diff --git a/media-libs/libemf/libemf-1.0.4-r1.ebuild b/media-libs/libemf/libemf-1.0.4-r1.ebuild
new file mode 100644
index 000000000000..39248699699a
--- /dev/null
+++ b/media-libs/libemf/libemf-1.0.4-r1.ebuild
@@ -0,0 +1,38 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+AUTOTOOLS_AUTORECONF=true
+
+inherit autotools-utils
+
+MY_P="${P/emf/EMF}"
+DESCRIPTION="Library implementation of ECMA-234 API for the generation of enhanced metafiles"
+HOMEPAGE="http://libemf.sourceforge.net/"
+SRC_URI="mirror://sourceforge/libemf/${MY_P}.tar.gz"
+
+LICENSE="LGPL-2.1 GPL-2"
+SLOT="0"
+KEYWORDS="amd64 -arm ppc ppc64 sparc x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux"
+IUSE="doc static-libs"
+
+S=${WORKDIR}/${MY_P}
+
+PATCHES=( "${FILESDIR}"/${P}-amd64-alpha.patch )
+
+src_prepare(){
+ sed -i 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/g' configure.ac || die
+ autotools-utils_src_prepare
+}
+
+src_configure() {
+ local myeconfargs=( --enable-editing )
+ autotools-utils_src_configure
+}
+
+src_install() {
+ use doc && HTML_DOCS=( doc/html/. )
+ autotools-utils_src_install
+}
diff --git a/media-libs/libemf/libemf-1.0.7.ebuild b/media-libs/libemf/libemf-1.0.7.ebuild
new file mode 100644
index 000000000000..695a61c45f62
--- /dev/null
+++ b/media-libs/libemf/libemf-1.0.7.ebuild
@@ -0,0 +1,36 @@
+# Copyright 1999-2015 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Id$
+
+EAPI=5
+
+AUTOTOOLS_AUTORECONF=true
+
+inherit autotools-utils
+
+MY_P="${P/emf/EMF}"
+DESCRIPTION="Library implementation of ECMA-234 API for the generation of enhanced metafiles"
+HOMEPAGE="http://libemf.sourceforge.net/"
+SRC_URI="mirror://sourceforge/libemf/${MY_P}.tar.gz"
+
+LICENSE="LGPL-2.1 GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 -arm ~ppc ~ppc64 ~sparc ~x86 ~amd64-fbsd ~x86-fbsd ~amd64-linux ~x86-linux"
+IUSE="doc static-libs"
+
+S=${WORKDIR}/${MY_P}
+
+src_prepare(){
+ sed -i 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/g' configure.ac || die
+ autotools-utils_src_prepare
+}
+
+src_configure() {
+ local myeconfargs=( --enable-editing )
+ autotools-utils_src_configure
+}
+
+src_install() {
+ use doc && HTML_DOCS=( doc/html/. )
+ autotools-utils_src_install
+}
diff --git a/media-libs/libemf/metadata.xml b/media-libs/libemf/metadata.xml
new file mode 100644
index 000000000000..9dc9ef9f1c8c
--- /dev/null
+++ b/media-libs/libemf/metadata.xml
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
+<pkgmetadata>
+ <maintainer>
+ <email>maintainer-needed@gentoo.org</email>
+ </maintainer>
+ <upstream>
+ <remote-id type="sourceforge">libemf</remote-id>
+ </upstream>
+</pkgmetadata>