work in progress, cleaned up the directories and split them up into folder which make more sense, Still need to compile libvitaboy and all the tools

This commit is contained in:
Jip 2024-05-13 18:38:21 +02:00
parent 66ce473514
commit 948bd8474c
1786 changed files with 571812 additions and 15332 deletions

View file

@ -0,0 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>IFPkgDescriptionDescription</key>
<string>A SIMD-accelerated JPEG codec that provides both the libjpeg and TurboJPEG APIs</string>
<key>IFPkgDescriptionTitle</key>
<string>@PACKAGE_NAME@</string>
<key>IFPkgDescriptionVersion</key>
<string>@VERSION@</string>
</dict>
</plist>

View file

@ -0,0 +1,44 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple Computer//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>CFBundleGetInfoString</key>
<string>@VERSION@, The libjpeg-turbo Project</string>
<key>CFBundleIdentifier</key>
<string>com.libjpeg-turbo.libjpeg-turbo</string>
<key>CFBundleShortVersionString</key>
<string>@VERSION@</string>
<key>IFMajorVersion</key>
<integer>1</integer>
<key>IFMinorVersion</key>
<integer>@BUILD@</integer>
<key>IFPkgFlagAllowBackRev</key>
<false/>
<key>IFPkgFlagAuthorizationAction</key>
<string>AdminAuthorization</string>
<key>IFPkgFlagBackgroundAlignment</key>
<string>topleft</string>
<key>IFPkgFlagBackgroundScaling</key>
<string>none</string>
<key>IFPkgFlagDefaultLocation</key>
<string>/</string>
<key>IFPkgFlagFollowLinks</key>
<true/>
<key>IFPkgFlagInstallFat</key>
<false/>
<key>IFPkgFlagIsRequired</key>
<false/>
<key>IFPkgFlagOverwritePermissions</key>
<false/>
<key>IFPkgFlagRelocatable</key>
<false/>
<key>IFPkgFlagRestartAction</key>
<string>NoRestart</string>
<key>IFPkgFlagRootVolumeOnly</key>
<true/>
<key>IFPkgFlagUpdateInstalledLanguages</key>
<false/>
<key>IFPkgFormatVersion</key>
<real>0.10000000149011612</real>
</dict>
</plist>

20
deps/libjpeg-turbo/release/License.rtf vendored Normal file
View file

@ -0,0 +1,20 @@
{\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf350
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
{\*\listtable{\list\listtemplateid1\listhybrid{\listlevel\levelnfc23\levelnfcn23\leveljc0\leveljcn0\levelfollow0\levelstartat1\levelspace360\levelindent0{\*\levelmarker \{disc\}}{\leveltext\leveltemplateid1\'01\uc0\u8226 ;}{\levelnumbers;}\fi-360\li720\lin720 }{\listname ;}\listid1}}
{\*\listoverridetable{\listoverride\listid1\listoverridecount0\ls1}}
\margl1440\margr1440\vieww9820\viewh8480\viewkind0
\deftab720
\pard\pardeftab720
\f0\fs24 \cf0 Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:\
\
\pard\tx220\tx720\pardeftab720\li720\fi-720
\ls1\ilvl0\cf0 {\listtext \'95 }Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimer.\
{\listtext \'95 }Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimer in the documentation and/or other materials provided with the distribution.\
{\listtext \'95 }Neither the name of the libjpeg-turbo Project nor the names of its contributors may be used to endorse or promote products derived from this software without specific prior written permission.\
\pard\pardeftab720\qc
\cf0 \
\pard\pardeftab720
\cf0 THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS", AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.\
}

13
deps/libjpeg-turbo/release/ReadMe.rtf vendored Normal file
View file

@ -0,0 +1,13 @@
{\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf360
{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
{\colortbl;\red255\green255\blue255;}
\margl1440\margr1440\vieww15200\viewh9600\viewkind0
\deftab720
\pard\pardeftab720\ql\qnatural
\f0\fs24 \cf0 libjpeg-turbo is a derivative of libjpeg that uses SIMD instructions (MMX, SSE2, NEON) to accelerate baseline JPEG compression and decompression on x86, x86-64, and ARM systems. On such systems, libjpeg-turbo is generally 2-4x as fast as the unmodified version of libjpeg, all else being equal.\
\
libjpeg-turbo was originally based on libjpeg/SIMD by Miyasaka Masaru, but the TigerVNC and VirtualGL projects made numerous enhancements to the codec in 2009, including improved support for Mac OS X, 64-bit support, support for 32-bit and big-endian pixel formats (RGBX, XBGR, etc.), accelerated Huffman encoding/decoding, and various bug fixes. The goal was to produce a fully open-source codec that could replace the partially closed-source TurboJPEG/IPP codec used by VirtualGL and TurboVNC. libjpeg-turbo generally achieves 80-120% of the performance of TurboJPEG/IPP. It is faster in some areas but slower in others.\
\
In early 2010, libjpeg-turbo spun off into its own independent project, with the goal of making high-speed JPEG compression/decompression technology available to a broader range of users and developers.\
}

19
deps/libjpeg-turbo/release/Welcome.rtf vendored Normal file
View file

@ -0,0 +1,19 @@
{\rtf1\ansi\ansicpg1252\cocoartf1038\cocoasubrtf350
{\fonttbl\f0\fswiss\fcharset0 Helvetica;\f1\fmodern\fcharset0 CourierNewPSMT;}
{\colortbl;\red255\green255\blue255;}
\margl1440\margr1440\vieww9000\viewh8400\viewkind0
\deftab720
\pard\pardeftab720\ql\qnatural
\f0\fs24 \cf0 This installer will install the libjpeg-turbo SDK and run-time libraries onto your computer so that you can use libjpeg-turbo to build new applications or accelerate existing ones. To remove the libjpeg-turbo package, run\
\
\pard\pardeftab720\ql\qnatural
\f1 \cf0 /opt/libjpeg-turbo/bin/uninstall\
\pard\pardeftab720\ql\qnatural
\f0 \cf0 \
from the command line.\
\
If TurboJPEG/IPP is currently installed, then it must be removed prior to installing libjpeg-turbo.\
}

1
deps/libjpeg-turbo/release/copyright vendored Normal file
View file

@ -0,0 +1 @@
libjpeg-turbo is released under a BSD-style license (see README and README-turbo.txt)

View file

@ -0,0 +1,26 @@
Package: {__PKGNAME}
Version: {__VERSION}-{__BUILD}
Section: misc
Priority: optional
Architecture: {__ARCH}
Essential: no
Maintainer: The libjpeg-turbo Project [http://www.libjpeg-turbo.org]
Description: A SIMD-accelerated JPEG codec that provides both the libjpeg and TurboJPEG APIs
libjpeg-turbo is a derivative of libjpeg that uses SIMD instructions (MMX,
SSE2, NEON) to accelerate baseline JPEG compression and decompression on x86,
x86-64, and ARM systems. On such systems, libjpeg-turbo is generally 2-4x as
fast as the unmodified version of libjpeg, all else being equal.
.
libjpeg-turbo was originally based on libjpeg/SIMD by Miyasaka Masaru, but
the TigerVNC and VirtualGL projects made numerous enhancements to the codec
in 2009, including improved support for Mac OS X, 64-bit support, support
for 32-bit and big-endian pixel formats (RGBX, XBGR, etc.), accelerated
Huffman encoding/decoding, and various bug fixes. The goal was to produce a
fully open-source codec that could replace the partially closed-source
TurboJPEG/IPP codec used by VirtualGL and TurboVNC. libjpeg-turbo generally
achieves 80-120% of the performance of TurboJPEG/IPP. It is faster in some
areas but slower in others.
.
In early 2010, libjpeg-turbo spun off into its own independent project, with
the goal of making high-speed JPEG compression/decompression technology
available to a broader range of users and developers.

View file

@ -0,0 +1,153 @@
!include x64.nsh
Name "@CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@"
OutFile "@CMAKE_BINARY_DIR@\${BUILDDIR}@INST_NAME@.exe"
InstallDir c:\@INST_DIR@
SetCompressor bzip2
Page directory
Page instfiles
UninstPage uninstConfirm
UninstPage instfiles
Section "@CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@ (required)"
!ifdef WIN64
${If} ${RunningX64}
${DisableX64FSRedirection}
${Endif}
!endif
SectionIn RO
!ifdef GCC
IfFileExists $SYSDIR/libturbojpeg.dll exists 0
!else
IfFileExists $SYSDIR/turbojpeg.dll exists 0
!endif
goto notexists
exists:
!ifdef GCC
MessageBox MB_OK "An existing version of the @CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@ is already installed. Please uninstall it first."
!else
MessageBox MB_OK "An existing version of the @CMAKE_PROJECT_NAME@ SDK for @INST_PLATFORM@ or the TurboJPEG SDK is already installed. Please uninstall it first."
!endif
quit
notexists:
SetOutPath $SYSDIR
!ifdef GCC
File "@CMAKE_BINARY_DIR@\libturbojpeg.dll"
!else
File "@CMAKE_BINARY_DIR@\${BUILDDIR}turbojpeg.dll"
!endif
SetOutPath $INSTDIR\bin
!ifdef GCC
File "/oname=libjpeg-@DLL_VERSION@.dll" "@CMAKE_BINARY_DIR@\sharedlib\libjpeg-*.dll"
!else
File "@CMAKE_BINARY_DIR@\sharedlib\${BUILDDIR}jpeg@DLL_VERSION@.dll"
!endif
File "@CMAKE_BINARY_DIR@\sharedlib\${BUILDDIR}cjpeg.exe"
File "@CMAKE_BINARY_DIR@\sharedlib\${BUILDDIR}djpeg.exe"
File "@CMAKE_BINARY_DIR@\sharedlib\${BUILDDIR}jpegtran.exe"
File "@CMAKE_BINARY_DIR@\${BUILDDIR}tjbench.exe"
File "@CMAKE_BINARY_DIR@\${BUILDDIR}rdjpgcom.exe"
File "@CMAKE_BINARY_DIR@\${BUILDDIR}wrjpgcom.exe"
SetOutPath $INSTDIR\lib
!ifdef GCC
File "@CMAKE_BINARY_DIR@\libturbojpeg.dll.a"
File "@CMAKE_BINARY_DIR@\libturbojpeg.a"
File "@CMAKE_BINARY_DIR@\sharedlib\libjpeg.dll.a"
File "@CMAKE_BINARY_DIR@\libjpeg.a"
!else
File "@CMAKE_BINARY_DIR@\${BUILDDIR}turbojpeg.lib"
File "@CMAKE_BINARY_DIR@\${BUILDDIR}turbojpeg-static.lib"
File "@CMAKE_BINARY_DIR@\sharedlib\${BUILDDIR}jpeg.lib"
File "@CMAKE_BINARY_DIR@\${BUILDDIR}jpeg-static.lib"
!endif
!ifdef JAVA
SetOutPath $INSTDIR\classes
File "@CMAKE_BINARY_DIR@\java\${BUILDDIR}turbojpeg.jar"
!endif
SetOutPath $INSTDIR\include
File "@CMAKE_BINARY_DIR@\jconfig.h"
File "@CMAKE_SOURCE_DIR@\jerror.h"
File "@CMAKE_SOURCE_DIR@\jmorecfg.h"
File "@CMAKE_SOURCE_DIR@\jpeglib.h"
File "@CMAKE_SOURCE_DIR@\turbojpeg.h"
SetOutPath $INSTDIR\doc
File "@CMAKE_SOURCE_DIR@\README"
File "@CMAKE_SOURCE_DIR@\README-turbo.txt"
File "@CMAKE_SOURCE_DIR@\example.c"
File "@CMAKE_SOURCE_DIR@\libjpeg.txt"
File "@CMAKE_SOURCE_DIR@\structure.txt"
File "@CMAKE_SOURCE_DIR@\usage.txt"
File "@CMAKE_SOURCE_DIR@\wizard.txt"
WriteRegStr HKLM "SOFTWARE\@INST_DIR@ @VERSION@" "Install_Dir" "$INSTDIR"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "DisplayName" "@CMAKE_PROJECT_NAME@ SDK v@VERSION@ for @INST_PLATFORM@"
WriteRegStr HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "UninstallString" '"$INSTDIR\uninstall_@VERSION@.exe"'
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "NoModify" 1
WriteRegDWORD HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@" "NoRepair" 1
WriteUninstaller "uninstall_@VERSION@.exe"
SectionEnd
Section "Uninstall"
!ifdef WIN64
${If} ${RunningX64}
${DisableX64FSRedirection}
${Endif}
!endif
SetShellVarContext all
DeleteRegKey HKLM "Software\Microsoft\Windows\CurrentVersion\Uninstall\@INST_DIR@ @VERSION@"
DeleteRegKey HKLM "SOFTWARE\@INST_DIR@ @VERSION@"
!ifdef GCC
Delete $INSTDIR\bin\libjpeg-@DLL_VERSION@.dll
Delete $SYSDIR\libturbojpeg.dll
Delete $INSTDIR\lib\libturbojpeg.dll.a"
Delete $INSTDIR\lib\libturbojpeg.a"
Delete $INSTDIR\lib\libjpeg.dll.a"
Delete $INSTDIR\lib\libjpeg.a"
!else
Delete $INSTDIR\bin\jpeg@DLL_VERSION@.dll
Delete $SYSDIR\turbojpeg.dll
Delete $INSTDIR\lib\jpeg.lib
Delete $INSTDIR\lib\jpeg-static.lib
Delete $INSTDIR\lib\turbojpeg.lib
Delete $INSTDIR\lib\turbojpeg-static.lib
!endif
!ifdef JAVA
Delete $INSTDIR\classes\turbojpeg.jar
!endif
Delete $INSTDIR\bin\cjpeg.exe
Delete $INSTDIR\bin\djpeg.exe
Delete $INSTDIR\bin\jpegtran.exe
Delete $INSTDIR\bin\tjbench.exe
Delete $INSTDIR\bin\rdjpgcom.exe
Delete $INSTDIR\bin\wrjpgcom.exe
Delete $INSTDIR\include\jconfig.h"
Delete $INSTDIR\include\jerror.h"
Delete $INSTDIR\include\jmorecfg.h"
Delete $INSTDIR\include\jpeglib.h"
Delete $INSTDIR\include\turbojpeg.h"
Delete $INSTDIR\uninstall_@VERSION@.exe
Delete $INSTDIR\doc\README
Delete $INSTDIR\doc\README-turbo.txt
Delete $INSTDIR\doc\example.c
Delete $INSTDIR\doc\libjpeg.txt
Delete $INSTDIR\doc\structure.txt
Delete $INSTDIR\doc\usage.txt
Delete $INSTDIR\doc\wizard.txt
RMDir "$INSTDIR\include"
RMDir "$INSTDIR\lib"
RMDir "$INSTDIR\doc"
!ifdef JAVA
RMDir "$INSTDIR\classes"
!endif
RMDir "$INSTDIR\bin"
RMDir "$INSTDIR"
SectionEnd

View file

@ -0,0 +1,112 @@
%ifarch x86_64
%define __lib lib64
%else
%define __lib lib
%endif
Summary: A SIMD-accelerated JPEG codec that provides both the libjpeg and TurboJPEG APIs
Name: @PACKAGE_NAME@
Version: @VERSION@
Vendor: The libjpeg-turbo Project
URL: http://www.libjpeg-turbo.org
Group: System Environment/Libraries
#-->Source0: http://prdownloads.sourceforge.net/libjpeg-turbo/libjpeg-turbo-%{version}.tar.gz
Release: @BUILD@
License: BSD-style
BuildRoot: %{_blddir}/%{name}-buildroot-%{version}-%{release}
Prereq: /sbin/ldconfig
Provides: %{name} = %{version}-%{release}, turbojpeg = 2.00
Obsoletes: turbojpeg
%description
libjpeg-turbo is a derivative of libjpeg that uses SIMD instructions (MMX,
SSE2, NEON) to accelerate baseline JPEG compression and decompression on x86,
x86-64, and ARM systems. On such systems, libjpeg-turbo is generally 2-4x as
fast as the unmodified version of libjpeg, all else being equal.
libjpeg-turbo was originally based on libjpeg/SIMD by Miyasaka Masaru, but
the TigerVNC and VirtualGL projects made numerous enhancements to the codec in
2009, including improved support for Mac OS X, 64-bit support, support for
32-bit and big-endian pixel formats (RGBX, XBGR, etc.), accelerated Huffman
encoding/decoding, and various bug fixes. The goal was to produce a fully
open-source codec that could replace the partially closed-source TurboJPEG/IPP
codec used by VirtualGL and TurboVNC. libjpeg-turbo generally achieves 80-120%
of the performance of TurboJPEG/IPP. It is faster in some areas but slower in
others.
In early 2010, libjpeg-turbo spun off into its own independent project, with
the goal of making high-speed JPEG compression/decompression technology
available to a broader range of users and developers.
#-->%prep
#-->%setup -q
#-->%build
#-->./configure libdir=/opt/%{name}/%{__lib} mandir=/opt/%{name}/man JPEG_LIB_VERSION=@JPEG_LIB_VERSION@ SO_MAJOR_VERSION=@SO_MAJOR_VERSION@ SO_MINOR_VERSION=@SO_MINOR_VERSION@ --with-pic @RPM_CONFIG_ARGS@
#-->make DESTDIR=$RPM_BUILD_ROOT libdir=/opt/%{name}/%{__lib} mandir=/opt/%{name}/man
%install
rm -rf $RPM_BUILD_ROOT
make install DESTDIR=$RPM_BUILD_ROOT libdir=/opt/%{name}/%{__lib} mandir=/opt/%{name}/man docdir=/opt/%{name}/doc exampledir=/opt/%{name}/doc
rm -f $RPM_BUILD_ROOT/opt/%{name}/%{__lib}/*.la
mkdir -p $RPM_BUILD_ROOT/usr/%{__lib}
mv $RPM_BUILD_ROOT/opt/%{name}/%{__lib}/libturbojpeg.* $RPM_BUILD_ROOT/usr/%{__lib}
/sbin/ldconfig -n $RPM_BUILD_ROOT/opt/%{name}/%{__lib}
/sbin/ldconfig -n $RPM_BUILD_ROOT/usr/%{__lib}
mkdir -p $RPM_BUILD_ROOT/usr/include
mv $RPM_BUILD_ROOT/opt/%{name}/include/turbojpeg.h $RPM_BUILD_ROOT/usr/include
ln -fs /usr/include/turbojpeg.h $RPM_BUILD_ROOT/opt/%{name}/include/
ln -fs /usr/%{__lib}/libturbojpeg.a $RPM_BUILD_ROOT/opt/%{name}/%{__lib}/
mkdir -p $RPM_BUILD_ROOT%{_defaultdocdir}
mv $RPM_BUILD_ROOT/opt/%{name}/doc $RPM_BUILD_ROOT%{_defaultdocdir}/%{name}-%{version}
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(-,root,root)
%dir %{_defaultdocdir}/%{name}-%{version}
%doc %{_defaultdocdir}/%{name}-%{version}/*
%dir /opt/%{name}
%dir /opt/%{name}/bin
/opt/%{name}/bin/cjpeg
/opt/%{name}/bin/djpeg
/opt/%{name}/bin/jpegtran
/opt/%{name}/bin/tjbench
/opt/%{name}/bin/rdjpgcom
/opt/%{name}/bin/wrjpgcom
%dir /opt/%{name}/%{__lib}
%ifarch x86_64
%else
/opt/%{name}/lib32
%endif
/opt/%{name}/%{__lib}/libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@
/opt/%{name}/%{__lib}/libjpeg.so.@SO_MAJOR_VERSION@
/opt/%{name}/%{__lib}/libjpeg.so
/opt/%{name}/%{__lib}/libjpeg.a
/opt/%{name}/%{__lib}/libturbojpeg.a
/usr/%{__lib}/libturbojpeg.so
/usr/%{__lib}/libturbojpeg.a
/usr/include/turbojpeg.h
%dir /opt/%{name}/include
/opt/%{name}/include/jconfig.h
/opt/%{name}/include/jerror.h
/opt/%{name}/include/jmorecfg.h
/opt/%{name}/include/jpeglib.h
/opt/%{name}/include/turbojpeg.h
%dir /opt/%{name}/man
%dir /opt/%{name}/man/man1
/opt/%{name}/man/man1/cjpeg.1*
/opt/%{name}/man/man1/djpeg.1*
/opt/%{name}/man/man1/jpegtran.1*
/opt/%{name}/man/man1/rdjpgcom.1*
/opt/%{name}/man/man1/wrjpgcom.1*
@JAVA_RPM_CONTENTS_1@
@JAVA_RPM_CONTENTS_2@
%changelog

View file

@ -0,0 +1,36 @@
#!/bin/sh
set -u
set -e
trap onexit INT
trap onexit TERM
trap onexit EXIT
TMPDIR=
onexit()
{
if [ ! "$TMPDIR" = "" ]; then
rm -rf $TMPDIR
fi
}
PACKAGE_NAME=@PACKAGE_NAME@
VERSION=@VERSION@
SRCDIR=@abs_top_srcdir@
umask 022
rm -f $PACKAGE_NAME-$VERSION-cygwin.tar.bz2
TMPDIR=`mktemp -d /tmp/ljtbuild.XXXXXX`
__PWD=`pwd`
make install DESTDIR=$TMPDIR/pkg mandir=/opt/$PACKAGE_NAME/man \
docdir=/usr/share/doc/$PACKAGE_NAME-$VERSION \
exampledir=/usr/share/doc/$PACKAGE_NAME-$VERSION
rm $TMPDIR/pkg/opt/$PACKAGE_NAME/lib/*.la
ln -fs lib $TMPDIR/pkg/opt/$PACKAGE_NAME/lib32
cd $TMPDIR/pkg
tar cfj ../$PACKAGE_NAME-$VERSION-cygwin.tar.bz2 *
cd $__PWD
mv $TMPDIR/*.tar.bz2 .
exit 0

85
deps/libjpeg-turbo/release/makedpkg.in vendored Normal file
View file

@ -0,0 +1,85 @@
#!/bin/sh
set -u
set -e
trap onexit INT
trap onexit TERM
trap onexit EXIT
TMPDIR=
onexit()
{
if [ ! "$TMPDIR" = "" ]; then
sudo rm -rf $TMPDIR
fi
}
makedeb()
{
SUPPLEMENT=$1
DIRNAME=$PACKAGE_NAME
if [ $SUPPLEMENT = 1 ]; then
PACKAGE_NAME=$PACKAGE_NAME\32
DEBARCH=amd64
__LIB=lib32
else
__LIB=lib
fi
umask 022
rm -f $PACKAGE_NAME\_$VERSION\_$DEBARCH.deb
TMPDIR=`mktemp -d /tmp/$PACKAGE_NAME-build.XXXXXX`
mkdir $TMPDIR/DEBIAN
(cat $SRCDIR/release/deb-control.tmpl | sed s/{__PKGNAME}/$PACKAGE_NAME/g \
| sed s/{__VERSION}/$VERSION/g | sed s/{__BUILD}/$BUILD/g \
| sed s/{__ARCH}/$DEBARCH/g > $TMPDIR/DEBIAN/control)
make install prefix=$TMPDIR/opt/$DIRNAME libdir=$TMPDIR/opt/$DIRNAME/$__LIB \
mandir=$TMPDIR/opt/$DIRNAME/man \
docdir=$TMPDIR/usr/share/doc/$DIRNAME-$VERSION \
exampledir=$TMPDIR/usr/share/doc/$DIRNAME-$VERSION
rm -f $TMPDIR/opt/$DIRNAME/$__LIB/*.la
if [ $SUPPLEMENT = 1 ]; then
rm -rf $TMPDIR/opt/$DIRNAME/include
rm -rf $TMPDIR/opt/$DIRNAME/man
rm -rf $TMPDIR/opt/$DIRNAME/bin
rm -rf $TMPDIR/opt/$DIRNAME/classes
rm -rf $TMPDIR/usr
fi
mkdir -p $TMPDIR/usr/$__LIB
mv $TMPDIR/opt/$DIRNAME/$__LIB/libturbojpeg.* $TMPDIR/usr/$__LIB
ln -fs /usr/$__LIB/libturbojpeg.a $TMPDIR/opt/$DIRNAME/$__LIB/
/sbin/ldconfig -n $TMPDIR/opt/$DIRNAME/$__LIB
/sbin/ldconfig -n $TMPDIR/usr/$__LIB
if [ ! $SUPPLEMENT = 1 ]; then
if [ "$DEBARCH" = "amd64" ]; then
ln -fs lib $TMPDIR/opt/$DIRNAME/lib64
else
if [ ! "$__LIB" = "lib32" ]; then
ln -fs lib $TMPDIR/opt/$DIRNAME/lib32
fi
fi
mkdir -p $TMPDIR/usr/include
mv $TMPDIR/opt/$DIRNAME/include/turbojpeg.h $TMPDIR/usr/include
ln -fs /usr/include/turbojpeg.h $TMPDIR/opt/$DIRNAME/include/
fi
sudo chown -Rh root:root $TMPDIR/*
dpkg -b $TMPDIR $PACKAGE_NAME\_$VERSION\_$DEBARCH.deb
}
PACKAGE_NAME=@PACKAGE_NAME@
VERSION=@VERSION@
BUILD=@BUILD@
DEBARCH=@DEBARCH@
SRCDIR=@abs_top_srcdir@
makedeb 0
if [ "$DEBARCH" = "i386" ]; then makedeb 1; fi
exit

225
deps/libjpeg-turbo/release/makemacpkg.in vendored Normal file
View file

@ -0,0 +1,225 @@
#!/bin/sh
set -u
set -e
trap onexit INT
trap onexit TERM
trap onexit EXIT
TMPDIR=
onexit()
{
if [ ! "$TMPDIR" = "" ]; then
sudo rm -rf $TMPDIR
fi
}
usage()
{
echo "$0 [-builddir32 [32-bit build dir]] [-builddirarmv6 [ARM v6 build dir]] [-builddirarmv7 [ARM v7 build dir]]"
exit 1
}
PACKAGE_NAME=@PACKAGE_NAME@
VERSION=@VERSION@
BUILD=@BUILD@
SRCDIR=@abs_top_srcdir@
BUILDDIR32=@abs_top_srcdir@/osxx86
BUILDDIRARMV6=@abs_top_srcdir@/iosarmv6
BUILDDIRARMV7=@abs_top_srcdir@/iosarmv7
WITH_JAVA=@WITH_JAVA@
while [ $# -gt 0 ]; do
case $1 in
-h*) usage 0 ;;
-builddir32)
if [ $# -gt 1 ]; then
if [[ ! "$2" =~ -.* ]]; then
BUILDDIR32=$2; shift
fi
fi
;;
-builddirarmv6)
if [ $# -gt 1 ]; then
if [[ ! "$2" =~ -.* ]]; then
BUILDDIRARMV6=$2; shift
fi
fi
;;
-builddirarmv7)
if [ $# -gt 1 ]; then
if [[ ! "$2" =~ -.* ]]; then
BUILDDIRARMV7=$2; shift
fi
fi
;;
esac
shift
done
PACKAGEMAKER=/Developer/Applications/Utilities/PackageMaker.app/Contents/MacOS/PackageMaker
if [ -f $PACKAGE_NAME-$VERSION.dmg ]; then
rm -f $PACKAGE_NAME-$VERSION.dmg
fi
umask 022
TMPDIR=`mktemp -d /tmp/$PACKAGE_NAME-build.XXXXXX`
PKGROOT=$TMPDIR/pkg/Package_Root
mkdir -p $PKGROOT
mkdir -p $PKGROOT/opt/$PACKAGE_NAME/bin
make install DESTDIR=$PKGROOT mandir=/opt/$PACKAGE_NAME/man \
docdir=/Library/Documentation/$PACKAGE_NAME \
exampledir=/Library/Documentation/$PACKAGE_NAME
rm -f $PKGROOT/opt/$PACKAGE_NAME/lib/*.la
mkdir -p $PKGROOT/usr/lib
mv $PKGROOT/opt/$PACKAGE_NAME/lib/libturbojpeg.* $PKGROOT/usr/lib
mkdir -p $PKGROOT/usr/include
mv $PKGROOT/opt/$PACKAGE_NAME/include/turbojpeg.h $PKGROOT/usr/include
if [ ! "$BUILDDIR32" = "" ]; then
if [ ! -d $BUILDDIR32 ]; then
echo ERROR: 32-bit build directory $BUILDDIR32 does not exist
exit 1
fi
if [ ! -f $BUILDDIR32/Makefile ]; then
echo ERROR: 32-bit build directory $BUILDDIR32 is not configured
exit 1
fi
mkdir -p $TMPDIR/dist.x86
pushd $BUILDDIR32
make install DESTDIR=$TMPDIR/dist.x86
popd
if [ ! -h $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib -a \
! -h $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib ]; then
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib \
-output $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib
elif [ ! -h $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib -a \
! -h $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib ]; then
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib \
-output $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@.dylib
fi
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libjpeg.a \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a \
-output $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libturbojpeg.dylib \
-arch x86_64 $PKGROOT/usr/lib/libturbojpeg.dylib \
-output $PKGROOT/usr/lib/libturbojpeg.dylib
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/lib/libturbojpeg.a \
-arch x86_64 $PKGROOT/usr/lib/libturbojpeg.a \
-output $PKGROOT/usr/lib/libturbojpeg.a
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/cjpeg \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/cjpeg \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/cjpeg
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/djpeg \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/djpeg \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/djpeg
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/jpegtran \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/jpegtran \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/jpegtran
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/tjbench \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/tjbench \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/tjbench
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/rdjpgcom \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/rdjpgcom \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/rdjpgcom
lipo -create \
-arch i386 $TMPDIR/dist.x86/opt/$PACKAGE_NAME/bin/wrjpgcom \
-arch x86_64 $PKGROOT/opt/$PACKAGE_NAME/bin/wrjpgcom \
-output $PKGROOT/opt/$PACKAGE_NAME/bin/wrjpgcom
fi
if [ ! "$BUILDDIRARMV6" = "" ]; then
if [ ! -d $BUILDDIRARMV6 ]; then
echo ERROR: ARM v6 build directory $BUILDDIRARMV6 does not exist
exit 1
fi
if [ ! -f $BUILDDIRARMV6/Makefile ]; then
echo ERROR: ARM v6 build directory $BUILDDIRARMV6 is not configured
exit 1
fi
mkdir -p $TMPDIR/dist.armv6
pushd $BUILDDIRARMV6
make install DESTDIR=$TMPDIR/dist.armv6
popd
lipo -create \
$PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a \
-arch arm $TMPDIR/dist.armv6/opt/$PACKAGE_NAME/lib/libjpeg.a \
-output $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a
lipo -create \
$PKGROOT/usr/lib/libturbojpeg.a \
-arch arm $TMPDIR/dist.armv6/opt/$PACKAGE_NAME/lib/libturbojpeg.a \
-output $PKGROOT/usr/lib/libturbojpeg.a
fi
if [ ! "$BUILDDIRARMV7" = "" ]; then
if [ ! -d $BUILDDIRARMV7 ]; then
echo ERROR: ARM v7 build directory $BUILDDIRARMV7 does not exist
exit 1
fi
if [ ! -f $BUILDDIRARMV7/Makefile ]; then
echo ERROR: ARM v7 build directory $BUILDDIRARMV7 is not configured
exit 1
fi
mkdir -p $TMPDIR/dist.armv7
pushd $BUILDDIRARMV7
make install DESTDIR=$TMPDIR/dist.armv7
popd
lipo -create \
$PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a \
-arch arm $TMPDIR/dist.armv7/opt/$PACKAGE_NAME/lib/libjpeg.a \
-output $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.a
lipo -create \
$PKGROOT/usr/lib/libturbojpeg.a \
-arch arm $TMPDIR/dist.armv7/opt/$PACKAGE_NAME/lib/libturbojpeg.a \
-output $PKGROOT/usr/lib/libturbojpeg.a
fi
install_name_tool -id /opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib $PKGROOT/opt/$PACKAGE_NAME/lib/libjpeg.@SO_MAJOR_VERSION@.dylib
install_name_tool -id libturbojpeg.dylib $PKGROOT/usr/lib/libturbojpeg.dylib
ln -fs /usr/include/turbojpeg.h $PKGROOT/opt/$PACKAGE_NAME/include/
ln -fs /usr/lib/libturbojpeg.a $PKGROOT/opt/$PACKAGE_NAME/lib/
if [ $WITH_JAVA = 1 ]; then
ln -fs libturbojpeg.dylib $PKGROOT/usr/lib/libturbojpeg.jnilib
fi
if [ ! -h $PKGROOT/opt/$PACKAGE_NAME/lib32 ]; then
ln -fs lib $PKGROOT/opt/$PACKAGE_NAME/lib32
fi
if [ ! -h $PKGROOT/opt/$PACKAGE_NAME/lib64 ]; then
ln -fs lib $PKGROOT/opt/$PACKAGE_NAME/lib64
fi
chmod 1775 $PKGROOT/Library
chmod 775 $PKGROOT/Library/Documentation
mkdir -p $TMPDIR/pkg/Resources
cp pkgscripts/Description.plist $TMPDIR/pkg/
cp pkgscripts/Info.plist $TMPDIR/pkg/
install -m 755 pkgscripts/uninstall $PKGROOT/opt/$PACKAGE_NAME/bin/
sudo chown -R root:admin $PKGROOT
sudo chown -R root:0 $PKGROOT/usr
cp $SRCDIR/release/License.rtf $SRCDIR/release/Welcome.rtf $SRCDIR/release/ReadMe.rtf $TMPDIR/pkg/Resources/
mkdir $TMPDIR/dmg
$PACKAGEMAKER -build -v -p $TMPDIR/dmg/$PACKAGE_NAME.pkg \
-f $PKGROOT -r $TMPDIR/pkg/Resources \
-i $TMPDIR/pkg/Info.plist -d $TMPDIR/pkg/Description.plist
hdiutil create -fs HFS+ -volname $PACKAGE_NAME-$VERSION \
-srcfolder "$TMPDIR/dmg" $TMPDIR/$PACKAGE_NAME-$VERSION.dmg
cp $TMPDIR/$PACKAGE_NAME-$VERSION.dmg .
exit

143
deps/libjpeg-turbo/release/makesunpkg.in vendored Normal file
View file

@ -0,0 +1,143 @@
#!/bin/sh
set -u
set -e
trap onexit INT
trap onexit TERM
trap onexit EXIT
TMPDIR=
onexit()
{
if [ ! "$TMPDIR" = "" ]; then
rm -rf $TMPDIR
fi
}
usage()
{
echo "$0 [combined [32-bit build dir.]]"
exit 1
}
COMBINED=0
PACKAGE_NAME=@PACKAGE_NAME@
VERSION=@VERSION@
BUILD=@BUILD@
PKGARCH=@DEBARCH@
SRCDIR=@abs_top_srcdir@
BUILDDIR32=@abs_top_srcdir@/solx86
WITH_JAVA=@WITH_JAVA@
if [ $# -gt 0 ]; then
if [ "$1" = "combined" ]; then
COMBINED=1
if [ $# -gt 1 ]; then BUILDDIR32=$2; fi
fi
fi
umask 022
TMPDIR=`mktemp -d /tmp/$PACKAGE_NAME-build.XXXXXX`
rm -f $PACKAGE_NAME.pkg.bz2
cp $SRCDIR/release/copyright $TMPDIR
touch $TMPDIR/depend
cp pkgscripts/pkginfo $TMPDIR/pkginfo
if [ "$PKGARCH" = "i386" ]; then
__LIB=lib
else
__LIB=lib/$PKGARCH
fi
if [ $COMBINED = 1 ]; then
if [ ! -d $BUILDDIR32 ]; then
echo ERROR: 32-bit build directory $BUILDDIR32 does not exist
exit 1
fi
if [ ! -f $BUILDDIR32/Makefile ]; then
echo ERROR: 32-bit build directory $BUILDDIR32 is not configured
exit 1
fi
PWD=`pwd`
cd $BUILDDIR32
make install DESTDIR=$TMPDIR mandir=/opt/$PACKAGE_NAME/man AM_MAKEFLAGS="mandir=/opt/$PACKAGE_NAME/man"
cd $PWD
fi
# This mess is to work around a bug in /usr/ccs/bin/make
make install DESTDIR=$TMPDIR libdir=/opt/$PACKAGE_NAME/$__LIB \
mandir=/opt/$PACKAGE_NAME/man docdir=/opt/$PACKAGE_NAME/doc \
exampledir=/opt/$PACKAGE_NAME/doc \
AM_MAKEFLAGS="libdir=/opt/$PACKAGE_NAME/$__LIB mandir=/opt/$PACKAGE_NAME/man docdir=/opt/$PACKAGE_NAME/doc exampledir=/opt/$PACKAGE_NAME/doc"
rm -f $TMPDIR/opt/$PACKAGE_NAME/$__LIB/*.la
cat >$TMPDIR/proto <<EOF
i copyright
i depend
i pkginfo
d none $PACKAGE_NAME 0755 root bin
d none $PACKAGE_NAME/bin 0755 root bin
f none $PACKAGE_NAME/bin/cjpeg 0755 root bin
f none $PACKAGE_NAME/bin/djpeg 0755 root bin
f none $PACKAGE_NAME/bin/jpegtran 0755 root bin
f none $PACKAGE_NAME/bin/tjbench 0755 root bin
f none $PACKAGE_NAME/bin/rdjpgcom 0755 root bin
f none $PACKAGE_NAME/bin/wrjpgcom 0755 root bin
d none $PACKAGE_NAME/lib 0755 root bin
EOF
if [ $COMBINED = 1 ]; then
cat >>$TMPDIR/proto <<EOF
f none $PACKAGE_NAME/lib/libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@ 0755 root bin
s none $PACKAGE_NAME/lib/libjpeg.so.@SO_MAJOR_VERSION@=libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@
s none $PACKAGE_NAME/lib/libjpeg.so=libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@
f none $PACKAGE_NAME/lib/libjpeg.a 0644 root bin
f none $PACKAGE_NAME/lib/libturbojpeg.so 0755 root bin
f none $PACKAGE_NAME/lib/libturbojpeg.a 0644 root bin
EOF
fi
if [ "${__LIB}" != "lib" ]; then
echo d none $PACKAGE_NAME/${__LIB} 0755 root bin >>$TMPDIR/proto
echo s none $PACKAGE_NAME/lib64=${__LIB} >>$TMPDIR/proto
echo s none $PACKAGE_NAME/lib/64=$PKGARCH >>$TMPDIR/proto
fi
cat >>$TMPDIR/proto <<EOF
f none $PACKAGE_NAME/${__LIB}/libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@ 0755 root bin
s none $PACKAGE_NAME/${__LIB}/libjpeg.so.@SO_MAJOR_VERSION@=libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@
s none $PACKAGE_NAME/${__LIB}/libjpeg.so=libjpeg.so.@SO_MAJOR_VERSION@.0.@SO_MINOR_VERSION@
f none $PACKAGE_NAME/${__LIB}/libjpeg.a 0644 root bin
f none $PACKAGE_NAME/${__LIB}/libturbojpeg.so 0755 root bin
f none $PACKAGE_NAME/${__LIB}/libturbojpeg.a 0644 root bin
s none $PACKAGE_NAME/lib32=lib
d none $PACKAGE_NAME/man 0755 root bin
d none $PACKAGE_NAME/man/man1 0755 root bin
d none $PACKAGE_NAME/man/man1/cjpeg.1 0644 root bin
d none $PACKAGE_NAME/man/man1/djpeg.1 0644 root bin
d none $PACKAGE_NAME/man/man1/jpegtran.1 0644 root bin
d none $PACKAGE_NAME/man/man1/rdjpgcom.1 0644 root bin
d none $PACKAGE_NAME/man/man1/wrjpgcom.1 0644 root bin
d none $PACKAGE_NAME/include 0755 root bin
f none $PACKAGE_NAME/include/jconfig.h 0644 root bin
f none $PACKAGE_NAME/include/jerror.h 0644 root bin
f none $PACKAGE_NAME/include/jmorecfg.h 0644 root bin
f none $PACKAGE_NAME/include/jpeglib.h 0644 root bin
f none $PACKAGE_NAME/include/turbojpeg.h 0644 root bin
d none $PACKAGE_NAME/doc 0755 root bin
f none $PACKAGE_NAME/doc/README 0644 root bin
f none $PACKAGE_NAME/doc/README-turbo.txt 0644 root bin
f none $PACKAGE_NAME/doc/example.c 0644 root bin
f none $PACKAGE_NAME/doc/libjpeg.txt 0644 root bin
f none $PACKAGE_NAME/doc/structure.txt 0644 root bin
f none $PACKAGE_NAME/doc/usage.txt 0644 root bin
f none $PACKAGE_NAME/doc/wizard.txt 0644 root bin
EOF
if [ $WITH_JAVA = 1 ]; then
echo d none $PACKAGE_NAME/classes 0755 root bin >>$TMPDIR/proto
echo f none $PACKAGE_NAME/classes/turbojpeg.jar 0644 root bin >>$TMPDIR/proto
fi
pkgmk -o -r $TMPDIR/opt -d $TMPDIR -a i386 -f $TMPDIR/proto
pkgtrans -s $TMPDIR $TMPDIR/$PACKAGE_NAME-$VERSION.pkg $PACKAGE_NAME
bzip2 $TMPDIR/$PACKAGE_NAME-$VERSION.pkg
cp $TMPDIR/$PACKAGE_NAME-$VERSION.pkg.bz2 .
exit

16
deps/libjpeg-turbo/release/pkginfo.in vendored Normal file
View file

@ -0,0 +1,16 @@
ARCH=i386
PKG=@PACKAGE_NAME@
NAME=@PACKAGE_NAME@ SDK and run time libraries
VERSION=@VERSION@,REV=@BUILD@
SUNW_PKGVERS=1.0
DESC=A SIMD-accelerated JPEG codec that provides both the libjpeg and TurboJPEG APIs
VENDOR=The libjpeg-turbo Project
HOTLINE=http://www.libjpeg-turbo.org
EMAIL=information@libjpeg-turbo.org
MAXINST=1
CATEGORY=application
BASEDIR=/opt
CLASSES=none
SUNW_PKG_ALLZONES=true
SUNW_PKG_HOLLOW=false
SUNW_PKG_THISZONE=false

90
deps/libjpeg-turbo/release/uninstall.in vendored Normal file
View file

@ -0,0 +1,90 @@
# Copyright (C)2009-2011 D. R. Commander. All Rights Reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# - Redistributions of source code must retain the above copyright notice,
# this list of conditions and the following disclaimer.
# - Redistributions in binary form must reproduce the above copyright notice,
# this list of conditions and the following disclaimer in the documentation
# and/or other materials provided with the distribution.
# - Neither the name of the libjpeg-turbo Project nor the names of its
# contributors may be used to endorse or promote products derived from this
# software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS",
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
# ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
# LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
# CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
# SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
# INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
# CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
# ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
# POSSIBILITY OF SUCH DAMAGE.
#!/bin/sh
if [ ! "`id -u`" = "0" ]; then
echo "ERROR: This script must be executed as root"
exit -1
fi
PACKAGE=@PACKAGE_NAME@
MACPACKAGE=com.$PACKAGE.$PACKAGE
RECEIPT=/Library/Receipts/$PACKAGE.pkg
LSBOM=
if [ -d $RECEIPT ]; then
LSBOM='lsbom -s -f -l '$RECEIPT'/Contents/Archive.bom'
else
LSBOM='pkgutil --files '$MACPACKAGE
fi
mylsbom()
{
$LSBOM || (echo "ERROR: Could not list package contents"; exit -1)
}
echo Removing package files ...
EXITSTATUS=0
pushd /
mylsbom | while read file; do
if [ ! -d "$file" ]; then rm "$file" 2>&1 || EXITSTATUS=-1; fi
done
popd
echo Removing package directories ...
if [ -d /opt/$PACKAGE/bin ]; then
rmdir /opt/$PACKAGE/bin 2>&1 || EXITSTATUS=-1
fi
if [ -d /opt/$PACKAGE/lib ]; then
rmdir /opt/$PACKAGE/lib 2>&1 || EXITSTATUS=-1
fi
if [ -d /opt/$PACKAGE/include ]; then
rmdir /opt/$PACKAGE/include 2>&1 || EXITSTATUS=-1
fi
rm /opt/$PACKAGE/lib32 2>&1 || EXITSTATUS=-1
rm /opt/$PACKAGE/lib64 2>&1 || EXITSTATUS=-1
if [ -d /opt/$PACKAGE/man/man1 ]; then
rmdir /opt/$PACKAGE/man/man1 2>&1 || EXITSTATUS=-1
fi
if [ -d /opt/$PACKAGE/man ]; then
rmdir /opt/$PACKAGE/man 2>&1 || EXITSTATUS=-1
fi
if [ -d /opt/$PACKAGE/classes ]; then
rmdir /opt/$PACKAGE/classes 2>&1 || EXITSTATUS=-1
fi
rmdir /opt/$PACKAGE 2>&1 || EXITSTATUS=-1
rmdir /Library/Documentation/$PACKAGE 2>&1 || EXITSTATUS=-1
if [ -d $RECEIPT ]; then
echo Removing package receipt ...
rm -r $RECEIPT 2>&1 || EXITSTATUS=-1
else
echo Forgetting package $MACPACKAGE ...
pkgutil --forget $MACPACKAGE
fi
exit $EXITSTATUS