Sophie

Sophie

distrib > Mageia > 1 > i586 > by-pkgid > a945f07a5540da5523b27c42944c3b2a > files > 4

gdal-1.8.0-2.mga1.src.rpm

%define _requires_exceptions devel\(libogdi31.*\)\\|devel\(libcfitsio.*\)\\|libgrass

%define major 1
%define libname %mklibname %{name} %{major}
%define libnamedev %mklibname %{name} -d
%define libnamedevstat %mklibname %{name} -d -s

# Build gdal against libgrass. It is better to instead compile the new plugin
# which builds against grass itself (and thus has more features than the
# libgrass5 version)
# In fact, building with direct grass support will break gdal on every grass
# upgrade, see http://n2.nabble.com/qgis-%2B-grass-plugin-%3D-gdal-problem-tp2394932p2405146.html
%define build_libgrass 0
%{?with_libgrass: %define build_libgrass 1}

%define ogdidir %{_includedir}
%define ogdidir %{_includedir}/ogdi

Name: gdal
Version: 1.8.0
Release: %mkrel 2
Summary: The Geospatial Data Abstraction Library (GDAL)
Group: Sciences/Geosciences
License: MIT
URL: http://www.gdal.org/
Source: ftp://ftp.remotesensing.org/pub/gdal/%{name}-%{version}.tar.gz
#Patch2: gdal-1.7.1-fix-str-fmt.patch
Patch3: gdal-1.6.0-fix-libname.patch
Patch4: gdal-fix-pythontools-install.patch
BuildRequires:	libpng-devel
BuildRequires:	zlib-devel
BuildRequires:	geotiff-devel >= 1.2.0
BuildRequires:	libpng-devel
BuildRequires:	libungif-devel
BuildRequires:	postgresql-devel
BuildRequires:	libjpeg-devel
BuildRequires:	proj-devel >= 4.4.7
BuildRequires:  doxygen
%if %{build_libgrass}
Requires:	grass >= 6.4.0
BuildRequires:	grass
%else
BuildConflicts:	%mklibname -d grass 5 0
%endif
BuildRequires:	libjasper-devel
BuildRequires:	libgeos-devel >= 2.2.3
BuildRequires:	netcdf-devel >= 3.6.2
BuildRequires:	ogdi-devel
BuildRequires:	cfitsio-devel
BuildRequires:	python-numpy-devel
BuildRequires:	python-setuptools
BuildRequires:	sqlite3-devel
#BuildRequires:	mysql-devel
#BuildRequires:	libdap-devel
BuildRequires:	librx-devel
BuildRequires:	unixODBC-devel
#BuildRequires:	xerces-c-devel
BuildRequires:  xerces-c-devel
BuildRequires:	hdf5-devel
BuildRequires:	swig
BuildRequires:  gd-devel
BuildRequires:  gcc-c++
BuildRequires:  lzma-devel
BuildRequires:  mysql-devel
BuildRequires:  php-devel

%description
The Geospatial Data Abstraction Library (GDAL) is a unifying
C/C++ API for accessing raster geospatial data, and currently
includes formats like GeoTIFF, Erdas Imagine, Arc/Info
Binary, CEOS, DTED, GXF, and SDTS. It is intended to provide
efficient access, suitable for use in viewer applications,
and also attempts to preserve coordinate systems and metadata.
Python, C, and C++ interfaces are available.

%package python
Summary: The Python bindings for the GDAL library
Group: Sciences/Geosciences
Requires: %{libname} = %{version}
%py_requires -d

%description python
The Python bindings for the GDAL library

%package -n %{libname}
Summary: Libraries required for the GDAL library
Group: System/Libraries
Provides: lib%{name} = %{version}

%description -n %{libname}
Libraries required for the GDAL library

%package -n %{libnamedev}
Summary: Development files for using the GDAL library
Group: Development/C
Requires: %{libname} = %{version}-%{release}
Provides: lib%{name}-devel = %{version}
Provides: %{name}-devel = %{version}

%description -n %{libnamedev}
Development files for using the GDAL library

%package -n %{libnamedevstat}
Summary: Development files for using the GDAL library
Group: Development/C
Requires: %{libnamedev} = %{version}-%{release}

%description -n %{libnamedevstat}
Development files for using the GDAL library

%prep
%setup -q
%patch3 -p0 -b .libname
%patch4 -p1 -b .pythontools

%build


%configure2_5x \
	--datadir=%_datadir/gdal \
	--includedir=%_includedir/gdal \
        --with-dods-root=no \
        --with-ogdi=%{ogdidir} \
        --with-cfitsio=yes \
        --with-geotiff=internal   \
        --with-libtiff=internal   \
        --with-libz=%_prefix      \
        --with-netcdf=%_prefix    \
        --with-hdf5=%_prefix      \
        --with-geos               \
        --with-jasper             \
        --with-png                \
        --with-gif                \
        --with-jpeg               \
        --with-odbc               \
        --with-sqlite3            \
        --with-mysql              \
        --with-curl               \
        --with-python             \
        --with-php                \
        --with-xerces=%_prefix         \
        --with-xerces-lib='-lxerces-c' \
        --with-xerces-inc=%_includedir \
        %if %{build_libgrass}
    	    --with-grass=%_libdir/grass64     \
        %endif
        --with-threads            \
        --with-liblzma=yes

        
perl -pi -e 's,PYTHON = no,PYTHON = /usr/bin/python,g' GDALmake.opt
make
make docs

%install
rm -Rf %buildroot
mkdir -p %{buildroot}/%py_platsitedir
export PYTHONPATH="%{buildroot}/%py_platsitedir"
export DESTDIR=%{buildroot}
unset PYTHONDONTWRITEBYTECODE
export INST_MAN=%{_mandir}
%makeinstall_std install-man
perl -pi -e 's,%{_prefix}/lib/,%{_libdir}/,g' %{buildroot}/%{_libdir}/libgdal.la

%multiarch_binaries %{buildroot}%{_bindir}/gdal-config


%clean
rm -rf %buildroot

%files
%defattr(-,root,root)
%{_datadir}/gdal/
%{_bindir}/*
%exclude %{_bindir}/gdal-config
%doc NEWS VERSION

%files -n %{libnamedev}
%defattr(-,root,root)
%{_bindir}/%{name}-config
%{_libdir}/*.so
%{_includedir}/*
%_docdir/*
%multiarch %{multiarch_bindir}/gdal-config

%files -n %{libnamedevstat}
%defattr(-,root,root)
%{_libdir}/*.a
%{_libdir}/*.la

%files -n %{libname}
%defattr(-,root,root)
%{_libdir}/*.so.%{major}*

%files python
%defattr(-,root,root,-)
%py_platsitedir/*




%changelog
* Tue Apr 19 2011 obgr_seneca <obgr_seneca> 1.8.0-2.mga1
+ Revision: 88459
- added php-devel BuildRequire
- new version 1.8.0

* Thu Mar 24 2011 ennael <ennael> 1.7.3-2.mga1
+ Revision: 76909
- clean spec file
- imported package gdal


* Tue Mar 01 2011 Funda Wang <fwang@mandriva.org> 1.7.3-2mdv2011.0
+ Revision: 641074
- build with internal tiff (bug#62602)

* Fri Nov 26 2010 Buchan Milne <bgmilne@mandriva.org> 1.7.3-1mdv2011.0
+ Revision: 601535
- update to new version 1.7.3

* Sat Nov 06 2010 Funda Wang <fwang@mandriva.org> 1.7.2-3mdv2011.0
+ Revision: 593869
- rebuild for py2.7

* Sat Aug 21 2010 Funda Wang <fwang@mandriva.org> 1.7.2-2mdv2011.0
+ Revision: 571629
- use standard detection on cfitsio
- rebuild for new cfitsio

* Wed Apr 28 2010 Emmanuel Andry <eandry@mandriva.org> 1.7.2-1mdv2010.1
+ Revision: 540548
- New version 1.7.2
- drop p2 (merged upstream)

* Tue Apr 06 2010 Buchan Milne <bgmilne@mandriva.org> 1.7.1-1mdv2010.1
+ Revision: 532048
- Enable bytecode compilation to fix python install on cooker
- Really fix ogdi include dir (distro-dependant since headers moved after 2010.0)
- Fix python install
- Require python-setuptools, and other fixes to make python installation work

  + Funda Wang <fwang@mandriva.org>
    - fix ogdi prefix
    - New version 1.7.1

* Mon Jan 18 2010 Emmanuel Andry <eandry@mandriva.org> 1.6.3-3mdv2010.1
+ Revision: 493446
- fix hdf5 linking
- fix netcdf detection

* Sat Jan 16 2010 Funda Wang <fwang@mandriva.org> 1.6.3-2mdv2010.1
+ Revision: 492251
- rebuild for new libjpeg v8

* Sat Dec 26 2009 Funda Wang <fwang@mandriva.org> 1.6.3-1mdv2010.1
+ Revision: 482365
- new version 1.6.3

* Fri Aug 21 2009 Emmanuel Andry <eandry@mandriva.org> 1.6.2-2mdv2010.0
+ Revision: 418957
- reenable hdf5

* Fri Aug 21 2009 Funda Wang <fwang@mandriva.org> 1.6.2-1mdv2010.0
+ Revision: 418926
- New version 1.6.2
- disable libdap support (bad version)
- rebuild

  + Buchan Milne <bgmilne@mandriva.org>
    - Move grass dependency inside conditional (dont require grass when not built with libgrass)

* Sun May 24 2009 Funda Wang <fwang@mandriva.org> 1.6.1-1mdv2010.0
+ Revision: 379203
- New version 1.6.1

* Fri May 22 2009 Funda Wang <fwang@mandriva.org> 1.6.0-4mdv2010.0
+ Revision: 378669
- fix libproj.so libname

  + Buchan Milne <bgmilne@mandriva.org>
    - Provide link to mail explaining why gdal should not be built directly against grass

* Thu Mar 05 2009 Funda Wang <fwang@mandriva.org> 1.6.0-3mdv2009.1
+ Revision: 348959
- do not build with grass

* Fri Jan 30 2009 Funda Wang <fwang@mandriva.org> 1.6.0-2mdv2009.1
+ Revision: 335594
- move requires to python sub package

* Thu Jan 29 2009 Funda Wang <fwang@mandriva.org> 1.6.0-1mdv2009.1
+ Revision: 335217
- build with grass
- disable broken mysql build
- fix BR
- gcc 42 is no needed
- fix file list
- New version 1.6.0
- rebuild

  + Oden Eriksson <oeriksson@mandriva.com>
    - rebuilt against mysql-5.1.30 libs

  + Olivier Blin <oblin@mandriva.com>
    - move libtool sed in prep

* Thu Nov 06 2008 Olivier Blin <oblin@mandriva.com> 1.5.2-3mdv2009.1
+ Revision: 300276
- bump release (to be consistent with 2009.0 media)

* Mon Oct 13 2008 Helio Chissini de Castro <helio@mandriva.com> 1.5.2-2mdv2009.1
+ Revision: 293254
- Disable hdf, since 2009.0 was released against a different API than the
  current released hda and simply devel packages fail to install. Should be
  reenabled after when hdf is recompiling again
- libdap uses their namespace now. Added a patch to fix compilation

* Sat Aug 16 2008 Buchan Milne <bgmilne@mandriva.org> 1.5.2-2mdv2009.0
+ Revision: 272605
- Revert conflicts that were committed in r272040
- Rebuild for cfitsio library version change

  + Emmanuel Andry <eandry@mandriva.org>
    - protect major
    - move .la file into static

* Sat Jun 21 2008 Buchan Milne <bgmilne@mandriva.org> 1.5.2-1mdv2009.0
+ Revision: 227710
- New version 1.5.2

  + Pixel <pixel@mandriva.com>
    - do not call ldconfig in %%post/%%postun, it is now handled by filetriggers

  + Oden Eriksson <oeriksson@mandriva.com>
    - 1.5.1
    - sync with fedora

* Fri Feb 08 2008 Helio Chissini de Castro <helio@mandriva.com> 1.5.0-4mdv2008.1
+ Revision: 164282
- Play nice with excludes in both archs

* Fri Feb 08 2008 Helio Chissini de Castro <helio@mandriva.com> 1.5.0-3mdv2008.1
+ Revision: 164186
- Major cleanup on gdal. now build finely in both i586 and x86_64, even with python.
- Splitted devel and devel-static

  + Emmanuel Andry <eandry@mandriva.org>
    - New version
    - spec refactoring (inspired from fedora)

  + Olivier Blin <oblin@mandriva.com>
    - restore BuildRoot

  + Thierry Vignaud <tv@mandriva.org>
    - kill re-definition of %%buildroot on Pixel's request

* Wed Sep 05 2007 Buchan Milne <bgmilne@mandriva.org> 1.4.2-1mdv2008.0
+ Revision: 80453
- New version 1.4.2

* Mon May 07 2007 Herton Ronaldo Krzesinski <herton@mandriva.com.br> 1.4.1-1mdv2008.0
+ Revision: 24873
- Updated to 1.4.1.
- Updated URL tag.
- Keep identation uniform in some places.


* Sun Jan 14 2007 Emmanuel Andry <eandry@mandriva.org> 1.4.0-1mdv2007.0
+ Revision: 108693
- New version 1.4.0

* Sun Nov 12 2006 Buchan Milne <bgmilne@mandriva.org> 1.3.2-6mdv2007.0
+ Revision: 83285
- Include changes from Franck Martin <franck@sopac.org>:
- added support for mysql

* Fri Sep 01 2006 Buchan Milne <bgmilne@mandriva.org> 1.3.2-5mdv2007.0
+ Revision: 59043
- bump release
- Ensure paths in libtool file are correct on x86_64 (fixes linking to gdal with libtool)
  Conflict with libgrass5-devel when building without obsolete libgrass

* Wed Aug 30 2006 Buchan Milne <bgmilne@mandriva.org> 1.3.2-4mdv2007.0
+ Revision: 58743
- force -fPIC to fix linking to gdal in x86_64
- filter bad ogdi require

* Thu Aug 24 2006 Buchan Milne <bgmilne@mandriva.org> 1.3.2-2mdv2007.0
+ Revision: 57696
- Merge changes that were lost when the SRPM was lost, but binaries were
  accepted making re-uploading the SRPM difficult, followed by an NMU into svn:
- dont buildrequire grass, we will add the plugin package
- dont try and ship python modules on x86_64 for now

* Sat Aug 05 2006 Helio Chissini de Castro <helio@mandriva.com> 1.3.2-1mdv2007.0
+ Revision: 51716
- New upstream version 1.3.2
- import gdal-1.2.6-4mdk

* Tue Jan 03 2006 Oden Eriksson <oeriksson@mandriva.com> 1.2.6-4mdk
- added one gcc4 patch by debian (P0)
- fix deps
- added one lib64 fix

* Fri Jun 03 2005 Nicolas Lécureuil <neoclust@mandriva.org> 1.2.6-3mdk
- Fix Description

* Fri Jun 03 2005 Nicolas Lécureuil <neoclust@mandriva.org> 1.2.6-2mdk
- Rebuild for missing source rpm

* Wed May 11 2005 Nicolas Lécureuil <neoclust@mandriva.org> 1.2.6-1mdk
- 1.2.6

* Wed May 04 2005 Nicolas Lécureuil <neoclust@mandriva.org> 1.2.5-3mdk
- Rebuild
- Fix MultiArch

* Sun Dec 05 2004 Michael Scherer <misc@mandrake.org> 1.2.5-2mdk
- Rebuild for new python

* Tue Nov 23 2004 Lenny Cartier <lenny@mandrakesoft.com> 1.2.5-1mdk
- 1.2.5

* Tue Sep 21 2004 Lenny Cartier <lenny@mandrakesoft.com> 1.2.2-1mdk
- 1.2.2

* Sat Jun 26 2004 Lenny Cartier <lenny@mandrakesoft.com> 1.2.1-1mdk
- 1.2.1

* Mon Jun 21 2004 Buchan Milne <bgmilne@linux-mandrake.com> 1.2.0-1mdk
- 1.2.0, drop p2
- build with ogdi,cfitsio,netcdf support
- correct major since lib naming issues are resolved