Sophie

Sophie

distrib > Mandriva > 10.2 > x86_64 > by-pkgid > 98ccdc98e74ecf771da42eeba8dd66d6 > files > 7

dcraw-6.35-2mdk.src.rpm

%define	name	dcraw
%define	version	6.35
%define	release	2mdk

%define withgimp1 0

Name:		%name
Version:	%version
Release:	%release
Summary:	Reads the raw image formats of more than 140 digital cameras
Group:		Graphics
URL:		http://www.cybercom.net/~dcoffin/dcraw/
Source0:	http://www.cybercom.net/~dcoffin/dcraw/dcraw.c.bz2
#Source1:	http://www.cybercom.net/~dcoffin/dcraw/ljpeg_decode.tar.bz2
Source2:	http://www.cybercom.net/~dcoffin/dcraw/rawphoto.c.bz2
#Source200:	http://www.cybercom.net/~dcoffin/dcraw/rawphoto.c.bz2
Source3:	http://www.cybercom.net/~dcoffin/dcraw/.badpixels.bz2
Source4:	http://www.cybercom.net/~dcoffin/dcraw/dcraw.1.bz2
Source5:	http://www.cybercom.net/~dcoffin/dcraw/dcwrap.bz2
Source6:	http://www.cybercom.net/~dcoffin/dcraw/parse.c.bz2
Source7:	http://www.cybercom.net/~dcoffin/dcraw/fixdates.c.bz2
Source8:	http://www.cybercom.net/~dcoffin/dcraw/decompress.c.bz2
Source9:	http://www.cybercom.net/~dcoffin/dcraw/pgm.c.bz2
Source210:	http://www.cybercom.net/~dcoffin/dcraw/sony_clear.c.bz2
Source10:	http://neuemuenze.heim1.tu-clausthal.de/~sven/crwinfo/CRWInfo-0.2.tar.bz2
Source11:	http://www.cybercom.net/~dcoffin/dcraw/fujiturn.c.bz2
Source220:	http://www.cybercom.net/~dcoffin/dcraw/renum.bz2
Source230:	http://www.cybercom.net/~dcoffin/dcraw/lcfile.bz2
# This is a copy of the dcraw home page with camera list, usage info, FAQ,
# ...
Source100:	http://www.cybercom.net/~dcoffin/dcraw/dcraw.html.bz2
Source110:	http://www.cybercom.net/~dcoffin/dcraw/secrets.html.bz2
# Remove multiple-line string constant from crwinfo.c, gcc cannot handle it
Patch0:		crwinfo-help.patch.bz2
License:	Distributable
# Having these programs is highly recommended
Requires:	jpeg-progs jhead metacam
%if %withgimp1
BuildRequires:	gimp-devel
%endif 
BuildRequires:	libgimp-devel >= 2.0
BuildRequires:	libjpeg-devel
Buildroot:	%_tmppath/%name-%version-%release-root

%description

Reads and processes raw images from more than 140 digital cameras.

Raw images are the data directly read from the CCD of the camera,
without in-camera processing, without lossy JPEG compression, and in
36 or 48 bits color depth (TIFF has 24 bits). Problem of the raw
images is that they are in proprietary, camera-specific formats as
once, there seems not to be a standard format for high-color-depth
images, and second, the raw images contain headers with information
about camera settings.

This is a collection of command line tools to read and convert the raw
image files and also to get camera setting information out of them.

%if %withgimp1
Please read the /usr/share/doc/%{name}-%{version}/dcraw.html file (all
programs mentioned in this file are included with this package and the
dcraw-gimp(2.0) packages) and the man page ("man dcraw").

Install also dcraw-gimp(2.0) if you want to be able to load raw image
files directly into the GIMP (2).

%else
Please read the /usr/share/doc/%{name}-%{version}/dcraw.html file (all
programs mentioned in this file are included with this package and the
dcraw-gimp2.0 packages) and the man page ("man dcraw").

Install also dcraw-gimp2.0 if you want to be able to load raw image
files directly into the GIMP 2.

%endif
This program does not download the files from the camera, it only
processes the already downloaded files. Depending on your camera
model, mount your camera as a USB mass-storage device, use GPhoto2
("gtkam", "digikam", "flphoto", "gphoto2"), or a flash card reader for
downloading the files.

Supported cameras:

        * Canon PowerShot 600
        * Canon PowerShot A5
        * Canon PowerShot A5 Zoom
        * Canon PowerShot A50
        * Canon PowerShot Pro70
        * Canon PowerShot Pro90 IS
        * Canon PowerShot G1
        * Canon PowerShot G2
        * Canon PowerShot G3
        * Canon PowerShot G5
        * Canon PowerShot G6
        * Canon PowerShot S30
        * Canon PowerShot S40
        * Canon PowerShot S45
        * Canon PowerShot S50
        * Canon PowerShot S60
        * Canon PowerShot S70
        * Canon PowerShot Pro1
        * Canon EOS D30
        * Canon EOS D60
        * Canon EOS 10D
        * Canon EOS 20D
        * Canon EOS 300D
        * Canon EOS DIGITAL REBEL
        * Canon EOS Kiss Digital
        * Canon EOS D2000C
        * Canon EOS-1D
        * Canon EOS-1DS
        * Canon EOS-1D Mark II
        * Canon EOS-1Ds Mark II
        * Casio QV-2000UX
        * Casio QV-3000EX
        * Casio QV-3500EX
        * Casio QV-4000
        * Casio QV-5700
        * Casio Exlim Pro 600
        * Casio Exlim Pro 700
        * Contax N DIGITAL
        * Creative PC-CAM 600
        * Epson R-D1
        * Fuji FinePix E550
        * Fuji FinePix F700
        * Fuji FinePix F810
        * Fuji FinePix S2Pro
        * Fuji FinePix S3Pro
        * Fuji FinePix S20Pro
        * Fuji FinePix S5000
        * Fuji FinePix S5100/S5500
        * Fuji FinePix S7000
        * Imacon Ixpress
        * Kodak DC20  (see Oliver Hartman's page,
              http://www.planet-interkom.de/oliver.hartmann/dc20secr.htm)
        * Kodak DC25 (see Jun-ichiro Itoh's page,
              http://www.itojun.org/diary/19961113/index.eng.html)
        * Kodak DC40 (aka "Logitech Fotoman Pixtura")
        * Kodak DC50
        * Kodak DC120 (also try kdc2tiff,
              http://kdc2tiff.sourceforge.net/)
        * Kodak DCS315C
        * Kodak DCS330C
        * Kodak DCS420
        * Kodak DCS460
        * Kodak DCS460A
        * Kodak DCS520C
        * Kodak DCS560C
        * Kodak DCS620C
        * Kodak DCS620X
        * Kodak DCS660C
        * Kodak DCS660M
        * Kodak DCS720X
        * Kodak DCS760C
        * Kodak DCS760M
        * Kodak EOSDCS1
        * Kodak EOSDCS3B
        * Kodak NC2000F
        * Kodak ProBack
        * Kodak PB645C
        * Kodak PB645H
        * Kodak PB645M
        * Kodak DCS Pro 14n
        * Kodak DCS Pro 14nx
        * Kodak DCS Pro SLR/c
        * Kodak DCS Pro SLR/n
        * Konica KD-400Z
        * Konica KD-510Z
        * Leaf Valeo 11
        * Leaf Valeo 22
        * Leaf Volare
        * Leica Digilux 2
        * Minolta DiMAGE 5
        * Minolta DiMAGE 7
        * Minolta DiMAGE 7i
        * Minolta DiMAGE 7Hi
        * Minolta DiMAGE A1
        * Minolta DiMAGE A2
        * Minolta DiMAGE A200
        * Minolta DiMAGE G400
        * Minolta DiMAGE G500
        * Minolta DiMAGE G600
        * Minolta DiMAGE Z2
        * Minolta DYNAX/MAXXUM 7D
        * Nikon D1
        * Nikon D1H
        * Nikon D1X
        * Nikon D100
        * Nikon D2H
        * Nikon D70
        * Nikon E950 ("DIAG RAW" hack)
        * Nikon E990 ("DIAG RAW" hack)
        * Nikon E995 ("DIAG RAW" hack)
        * Nikon E2100 ("DIAG RAW" hack)
        * Nikon E2500 ("DIAG RAW" hack)
        * Nikon E3700 ("DIAG RAW" hack)
        * Nikon E4300 ("DIAG RAW" hack)
        * Nikon E4500 ("DIAG RAW" hack)
        * Nikon E5000
        * Nikon E5400
        * Nikon E5700
        * Nikon E8400
        * Nikon E8700
        * Nikon E8800
        * Olympus C5050Z
        * Olympus C5060WZ
        * Olympus C70Z,C7000Z
        * Olympus C8080WZ
        * Olympus E-1
        * Olympus E-10
        * Olympus E-20
        * Olympus E-300
        * Panasonic DMC-LC1
        * Pentax *ist D
        * Pentax *ist DS
        * Pentax Optio S
        * Pentax Optio S4
        * Pentax Optio 33WR
        * Phase One LightPhase
        * Phase One H10
        * Phase One H20
        * Phase One H25
        * Rollei d530flex
        * Sigma SD9
        * Sigma SD10
        * Sinar 12582980-byte
        * Sony DSC-F828
        * Sony DSC-V3 



On cameras which need the "DIAG RAW" hack, the manufacturer does not
support raw image capturing, neither by buttons/menues on the camera,
nor by the bundled Windows/Mac software. Please have a look at
http://e2500.narod.ru/raw_format_e.htm. Neither Mandrakesoft nor the
author of dcraw overtakes any responsability on your camera when using
the "DIAG RAW" hack. On Casio cameras (at least the old models) follow
the instructions on http://www.inweb.ch/foto/rawformat.html and read also
http://forums.dpreview.com/forums/read.asp?forum=1015&message=4961779.
For the Minolta DiMAGE G400 and G500 see http://myfototest.narod.ru/.
On all other cameras take raw pictures following the manufacturer's
instructions, as they support raw shooting officially.


%if %withgimp1
%package gimp
Summary: 	A GIMP plug-in to load raw image files of digital cameras
Group: 		Graphics
Requires: 	gimp dcraw
 
%description gimp

GIMP 1.2.x plug-in to load all raw image files of digital cameras
supported by the dcraw package. This allows direct editing of the
original images of the camera, without any conversion or compression
loss.

%endif
%package gimp2.0
Summary: 	A GIMP plug-in to load raw files of digicams (GIMP 2.2.x)
Group: 		Graphics
Requires: 	gimp dcraw
Conflicts:	rawphoto ufraw
 
%description gimp2.0

GIMP 2.2.x plug-in to load all raw image files of digital cameras
supported by the dcraw package. This allows direct editing of the
original images of the camera, without any conversion or compression
loss.


%prep
rm -rf $RPM_BUILD_DIR/%{name}-%{version}
mkdir $RPM_BUILD_DIR/%{name}-%{version}
%if %withgimp1
mkdir $RPM_BUILD_DIR/%{name}-%{version}/gimp
%endif
mkdir $RPM_BUILD_DIR/%{name}-%{version}/gimp2.0
cd $RPM_BUILD_DIR/%{name}-%{version}

bzcat %{SOURCE0} > dcraw.c
%if %withgimp1
bzcat %{SOURCE2} > gimp/rawphoto.c
%endif
bzcat %{SOURCE2} > gimp2.0/rawphoto.c
bzcat %{SOURCE3} > .badpixels
bzcat %{SOURCE4} > dcraw.1
bzcat %{SOURCE5} > dcwrap
bzcat %{SOURCE6} > parse.c
bzcat %{SOURCE7} > fixdates.c
bzcat %{SOURCE8} > decompress.c
bzcat %{SOURCE9} > pgm.c
bzcat %{SOURCE210} > sony_clear.c
bzcat %{SOURCE11} > fujiturn.c
bzcat %{SOURCE220} > renum
bzcat %{SOURCE230} > lcfile
bzcat %{SOURCE100} > dcraw.html
bzcat %{SOURCE110} > secrets.html
#setup -q -T -D -a 1 -n %{name}-%{version}
#cd ljpeg_decode
#ln -s ../dcraw.c .
#cd ..
%setup -q -T -D -a 10 -n %{name}-%{version}
cd CRWInfo*
%patch0 -p0
cd ..

%build
cd $RPM_BUILD_DIR/%{name}-%{version}

gcc ${CFLAGS:-%optflags} -lm -ljpeg -o dcraw dcraw.c

# Build simple C programs
for file in *.c; do
   if [ "$file" != "dcraw.c" ]; then
      gcc ${CFLAGS:-%optflags} -lm -o ${file%.c} $file
   fi
done

# Build GIMP plug-in
%if %withgimp1
gimptool-1.2 --build gimp/rawphoto.c
mv rawphoto gimp
%endif
gimptool-2.0 --build gimp2.0/rawphoto.c
mv rawphoto gimp2.0

# Build programs provided in tarballs
cd CRWInfo*
%make
cd ..

#cd ljpeg_decode
#make
#cd ..

%install
cd $RPM_BUILD_DIR/%{name}-%{version}

# Directories
install -d %{buildroot}%{_bindir}
install -d %{buildroot}%{_mandir}/man1
install -d %{buildroot}%{_docdir}/%{name}-%{version}
%if %withgimp1
install -d %{buildroot}%{_libdir}/gimp/1.2/plug-ins
%endif
install -d %{buildroot}%{_libdir}/gimp/2.0/plug-ins

# Program files
#install -m 755 ljpeg_decode/dcraw %{buildroot}%{_bindir}
install -m 755 dcraw %{buildroot}%{_bindir}
install -m 755 decompress %{buildroot}%{_bindir}
install -m 755 fixdates %{buildroot}%{_bindir}
install -m 755 fujiturn %{buildroot}%{_bindir}
install -m 755 parse %{buildroot}%{_bindir}
install -m 755 pgm %{buildroot}%{_bindir}
%if %withgimp1
install -m 755 gimp/rawphoto %{buildroot}%{_libdir}/gimp/1.2/plug-ins
%endif
install -m 755 gimp2.0/rawphoto %{buildroot}%{_libdir}/gimp/2.0/plug-ins
install -m 755 CRWInfo*/crwinfo %{buildroot}%{_bindir}
install -m 755 sony_clear %{buildroot}%{_bindir}
install -m 755 renum %{buildroot}%{_bindir}
install -m 755 lcfile %{buildroot}%{_bindir}

# Documentation
install -m 644 dcraw.1 %{buildroot}%{_mandir}/man1
install -m 644 dcraw.html %{buildroot}%{_docdir}/%{name}-%{version}
install -m 644 secrets.html %{buildroot}%{_docdir}/%{name}-%{version}
install -m 644 .badpixels %{buildroot}%{_docdir}/%{name}-%{version}/badpixels
install -m 644 CRWInfo*/README %{buildroot}%{_docdir}/%{name}-%{version}/README.crwinfo
install -m 644 CRWInfo*/spec %{buildroot}%{_docdir}/%{name}-%{version}/spec.crwinfo

%clean
rm -fr %buildroot

%files
%defattr(-,root,root)
%docdir %{_docdir}/%{name}-%{version}
%_bindir/*
%_mandir/man1/*
%_docdir/*

%if %withgimp1
%files gimp
%defattr(-,root,root)
%{_libdir}/gimp/1.2/plug-ins/*
%endif

%files gimp2.0
%defattr(-,root,root)
%{_libdir}/gimp/2.0/plug-ins/*

%changelog
* Mon Mar  7 2005 Till Kamppeter <till@mandrakesoft.com> 6.35-2mdk
- Added "Conflicts: ufraw" to the GIMP 2 plugin package.

* Mon Mar  7 2005 Till Kamppeter <till@mandrakesoft.com> 6.35-1mdk
- Updated to version 6.35.
- Updated also: parse.
- Updated to "Requires: jpeg-progs".
- Updated to "Requires: gimp" (it is every day changing).

* Fri Feb 11 2005 Till Kamppeter <till@mandrakesoft.com> 6.34-1mdk
- Updated to version 6.34.
- Updated also: dcwrap, parse, rawphoto.

* Sat Jan 15 2005 Couriousous <couriousous@mandrake.org> 6.18-2mdk
- Fix gimp requires

* Fri Dec 17 2004 Till Kamppeter <till@mandrakesoft.com> 6.18-1mdk
- Updated to version 6.18 (New cameras supported, especially all recent
  DSLRs).

* Tue Sep 07 2004 Christiaan Welvaart <cjw@daneel.dyndns.org> 0.20040813-2mdk
- add BuildRequires: libjpeg-devel

* Fri Aug 13 2004 Till Kamppeter <till@mandrakesoft.com> 0.20040813-1mdk
- Updated to the state of 13/08/2004 (More camera models supported).
- Removed support for GIMP 1.x as dcraw is in main and GIMP 1.x in contrib.

* Tue May 11 2004 Till Kamppeter <till@mandrakesoft.com> 0.20040511-1mdk
- Updated to the state of 11/05/2004 (Many new camera models supported).

* Thu Mar 25 2004 Thierry Vignaud <tvignaud@mandrakesoft.com> 0.20040317-2mdk
- rebuild for gimp2

* Wed Mar 17 2004 Till Kamppeter <till@mandrakesoft.com> 0.20040317-1mdk
- Updated to the state of 15/12/2003 (Many new camera models supported,
  GIMP 2.0 support, some new tools added).

* Mon Dec 15 2003 Till Kamppeter <till@mandrakesoft.com> 0.20031215-1mdk
- Updated to the state of 15/12/2003 (Many new camera models supported).

* Sun Sep 28 2003 Till Kamppeter <till@mandrakesoft.com> 0.20030928-2mdk
- Fixed patch to correct crwinfo help text.

* Sun Sep 28 2003 Till Kamppeter <till@mandrakesoft.com> 0.20030928-1mdk
- First release for Mandrake Linux