FreeImage: new package

This commit is contained in:
suvari
2021-05-28 18:37:50 +03:00
parent 8a865cf870
commit ae8d73f6f8
8 changed files with 20180 additions and 19940 deletions
+24
View File
@@ -0,0 +1,24 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt
from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
from pisi.actionsapi import shelltools
from pisi.actionsapi import get
#WorkDir = get.srcNAME()
def build():
shelltools.system('export CFLAGS="$CFLAGS -fPIC -fexceptions -fvisibility=hidden -DNO_LCMS"')
shelltools.system('export CXXFLAGS="$CXXFLAGS -fPIC -fexceptions -fvisibility=hidden -DNO_LCMS"')
shelltools.system('sed -i "1 i #include <cstring>" Source/OpenEXR/IlmImf/ImfAutoArray.h')
autotools.make()
def install():
autotools.rawInstall("DESTDIR=%s \
LIBDIR=/usr/lib" % get.installDIR())
pisitools.dodoc("*.txt", "README.linux")
@@ -0,0 +1,50 @@
--- FreeImage/Source/FreeImage/PluginRAW.cpp.orig 2020-07-23 17:27:57.937848902 +0000
+++ FreeImage/Source/FreeImage/PluginRAW.cpp 2020-07-23 17:28:59.482079468 +0000
@@ -63,17 +63,14 @@
}
int read(void *buffer, size_t size, size_t count) {
- if(substream) return substream->read(buffer, size, count);
return _io->read_proc(buffer, (unsigned)size, (unsigned)count, _handle);
}
int seek(INT64 offset, int origin) {
- if(substream) return substream->seek(offset, origin);
return _io->seek_proc(_handle, (long)offset, origin);
}
INT64 tell() {
- if(substream) return substream->tell();
return _io->tell_proc(_handle);
}
@@ -83,13 +80,11 @@
int get_char() {
int c = 0;
- if(substream) return substream->get_char();
if(!_io->read_proc(&c, 1, 1, _handle)) return -1;
return c;
}
char* gets(char *buffer, int length) {
- if (substream) return substream->gets(buffer, length);
memset(buffer, 0, length);
for(int i = 0; i < length; i++) {
if(!_io->read_proc(&buffer[i], 1, 1, _handle))
@@ -104,7 +99,6 @@
std::string buffer;
char element = 0;
bool bDone = false;
- if(substream) return substream->scanf_one(fmt,val);
do {
if(_io->read_proc(&element, 1, 1, _handle) == 1) {
switch(element) {
@@ -127,7 +121,6 @@
}
int eof() {
- if(substream) return substream->eof();
return (_io->tell_proc(_handle) >= _eof);
}
+81
View File
@@ -0,0 +1,81 @@
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "https://pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
<Source>
<Name>FreeImage</Name>
<Homepage>http://freeimage.sourceforge.net</Homepage>
<Packager>
<Name>PisiLinux Community</Name>
<Email>admins@pisilinux.org</Email>
</Packager>
<License>GPLv2</License>
<IsA>library</IsA>
<Summary>An Open Source library project</Summary>
<Description>FreeImage is an Open Source library project for developers who would like to support popular graphics image formats like PNG, BMP, JPEG, TIFF and others as needed by today's multimedia applications.</Description>
<Archive sha1sum="38daa9d8f1bca2330a2eaa42ec66fbe6ede7dce9" type="zip">https://sourceforge.net/projects/freeimage/files/Source%20Distribution/3.18.0/FreeImage3180.zip</Archive>
<BuildDependencies>
<Dependency>dos2unix</Dependency>
<Dependency>tiff-devel</Dependency>
<Dependency>webp-devel</Dependency>
<Dependency>mesa-devel</Dependency>
<Dependency>libmng-devel</Dependency>
<Dependency>libraw-devel</Dependency>
<Dependency>openexr-devel</Dependency>
<Dependency>mesa-glu-devel</Dependency>
<Dependency>openjpeg2-devel</Dependency>
<Dependency>libjpeg-turbo-devel</Dependency>
<!-- Note to the packager: Later, check whether
the package can use external raw package or not
<Dependency>libopenraw-devel</Dependency>
-->
</BuildDependencies>
<Patches>
<Patch>freeimage-libraw-0.20.patch</Patch>
</Patches>
</Source>
<Package>
<Name>FreeImage</Name>
<RuntimeDependencies>
<Dependency>tiff</Dependency>
<Dependency>webp</Dependency>
<Dependency>mesa</Dependency>
<Dependency>libgcc</Dependency>
<Dependency>libmng</Dependency>
<Dependency>libraw</Dependency>
<Dependency>dos2unix</Dependency>
<Dependency>mesa-glu</Dependency>
<Dependency>openjpeg2</Dependency>
<Dependency>openexr-libs</Dependency>
<Dependency>libjpeg-turbo</Dependency>
<!--
<Dependency>libopenraw</Dependency>
-->
</RuntimeDependencies>
<Files>
<Path fileType="library">/usr/lib</Path>
<Path fileType="doc">/usr/share/doc</Path>
</Files>
</Package>
<Package>
<Name>FreeImage-devel</Name>
<Summary>Development files for FreeImage</Summary>
<RuntimeDependencies>
<Dependency release="current">FreeImage</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="header">/usr/include</Path>
</Files>
</Package>
<History>
<Update release="1">
<Date>2021-05-25</Date>
<Version>3.18.0</Version>
<Comment>First release</Comment>
<Name>Kamil Atlı</Name>
<Email>suvari@pisilinux.org</Email>
</Update>
</History>
</PISI>
@@ -0,0 +1,12 @@
<?xml version="1.0" ?>
<PISI>
<Source>
<Name>FreeImage</Name>
<Description xml:lang="es">FreeImage es un proyecto de librería código abierto para desarrolladores que quisieran soportar formatos populares de imágenes como PNG, BMP, JPEG, TIFF y otros, usados en aplicaciones multimedia actuales</Description>
</Source>
<Package>
<Name>FreeImage-devel</Name>
<Summary xml:lang="tr">FreeImage için geliştirme dosyaları</Summary>
</Package>
</PISI>