- Enable udunits support add use system udunits.dat
This commit is contained in:
parent
5858210c69
commit
08cda3c36b
@ -7,8 +7,6 @@
|
|||||||
#define IncSearch -I/usr/include/netcdf
|
#define IncSearch -I/usr/include/netcdf
|
||||||
#define LibSearch -L@libdir@/hdf
|
#define LibSearch -L@libdir@/hdf
|
||||||
|
|
||||||
#define BuildUdunits TRUE
|
|
||||||
#define UdUnitslib
|
|
||||||
#define BuildV5D FALSE
|
#define BuildV5D FALSE
|
||||||
#define BuildHDFEOS FALSE
|
#define BuildHDFEOS FALSE
|
||||||
#define BuildTRIANGLE 0
|
#define BuildTRIANGLE 0
|
||||||
|
25
ncl-5.0.0-udunits.patch
Normal file
25
ncl-5.0.0-udunits.patch
Normal file
@ -0,0 +1,25 @@
|
|||||||
|
--- ncl_ncarg-5.0.0/ni/src/lib/nfp/udunitsW.c.udunits 2006-12-10 19:07:06.000000000 -0700
|
||||||
|
+++ ncl_ncarg-5.0.0/ni/src/lib/nfp/udunitsW.c 2008-11-27 08:41:11.000000000 -0700
|
||||||
|
@@ -23,21 +23,7 @@
|
||||||
|
*/
|
||||||
|
path = getenv("UDUNITS_PATH");
|
||||||
|
if ((void *)path == (void *)NULL) {
|
||||||
|
- path = _NGGetNCARGEnv("udunits");
|
||||||
|
- if ((void *)path != (void *)NULL) {
|
||||||
|
- strcpy(udunits_file,path);
|
||||||
|
- strcat(udunits_file,_NhlPATHDELIMITER);
|
||||||
|
- strcat(udunits_file,"udunits.dat");
|
||||||
|
- utret = utInit(udunits_file);
|
||||||
|
- }
|
||||||
|
- else {
|
||||||
|
-/*
|
||||||
|
- * Use path built-in at compile time. It's not a good thing if we reach
|
||||||
|
- * this point, because the "_NGGetNCARGEnv" call above should have
|
||||||
|
- * returned a valid path.
|
||||||
|
- */
|
||||||
|
- utret = utInit("");
|
||||||
|
- }
|
||||||
|
+ path = "/etc/udunits.dat";
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
/*
|
13
ncl.spec
13
ncl.spec
@ -1,6 +1,6 @@
|
|||||||
Name: ncl
|
Name: ncl
|
||||||
Version: 5.0.0
|
Version: 5.0.0
|
||||||
Release: 12%{?dist}
|
Release: 13%{?dist}
|
||||||
Summary: NCAR Command Language and NCAR Graphics
|
Summary: NCAR Command Language and NCAR Graphics
|
||||||
|
|
||||||
Group: Applications/Engineering
|
Group: Applications/Engineering
|
||||||
@ -42,6 +42,8 @@ Patch11: ncl-5.0.0-build_n_scripts.patch
|
|||||||
Patch12: ncl-5.0.0-netcdff.patch
|
Patch12: ncl-5.0.0-netcdff.patch
|
||||||
Patch13: ncl-5.0.0-includes.patch
|
Patch13: ncl-5.0.0-includes.patch
|
||||||
Patch14: ncl-5.0.0-uint32.patch
|
Patch14: ncl-5.0.0-uint32.patch
|
||||||
|
# Use /etc/udunits.dat
|
||||||
|
Patch15: ncl-5.0.0-udunits.patch
|
||||||
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
BuildRoot: %{_tmppath}/%{name}-%{version}-%{release}-root-%(%{__id_u} -n)
|
||||||
|
|
||||||
BuildRequires: /bin/csh, gcc-gfortran, netcdf-devel, hdf-devel >= 4.2r2, libjpeg-devel
|
BuildRequires: /bin/csh, gcc-gfortran, netcdf-devel, hdf-devel >= 4.2r2, libjpeg-devel
|
||||||
@ -49,6 +51,8 @@ BuildRequires: g2clib-devel, libnc-dap-devel, librx-devel, atlas-devel
|
|||||||
# imake needed for makedepend
|
# imake needed for makedepend
|
||||||
BuildRequires: imake, libXt-devel, libXaw-devel, libXext-devel, libXpm-devel
|
BuildRequires: imake, libXt-devel, libXaw-devel, libXext-devel, libXpm-devel
|
||||||
BuildRequires: byacc, flex
|
BuildRequires: byacc, flex
|
||||||
|
BuildRequires: udunits-devel
|
||||||
|
Requires: udunits
|
||||||
|
|
||||||
Provides: ncarg = %{version}-%{release}
|
Provides: ncarg = %{version}-%{release}
|
||||||
Obsoletes: ncarg < %{version}-%{release}
|
Obsoletes: ncarg < %{version}-%{release}
|
||||||
@ -144,6 +148,7 @@ for file in */*.ncl; do
|
|||||||
done
|
done
|
||||||
popd
|
popd
|
||||||
|
|
||||||
|
|
||||||
%build
|
%build
|
||||||
# short-cicuit:
|
# short-cicuit:
|
||||||
./config/ymkmf
|
./config/ymkmf
|
||||||
@ -171,6 +176,8 @@ do
|
|||||||
manname=`basename $manpage`
|
manname=`basename $manpage`
|
||||||
mv $manpage $RPM_BUILD_ROOT%{_mandir}/man3/%{name}_$manname
|
mv $manpage $RPM_BUILD_ROOT%{_mandir}/man3/%{name}_$manname
|
||||||
done
|
done
|
||||||
|
# Use system udunits
|
||||||
|
rm -r $RPM_BUILD_ROOT%{_datadir}/ncarg/udunits
|
||||||
# Remove $RPM_BUILD_ROOT from MakeNcl
|
# Remove $RPM_BUILD_ROOT from MakeNcl
|
||||||
#sed -i -e s,$RPM_BUILD_ROOT,,g $RPM_BUILD_ROOT%{_bindir}/MakeNcl
|
#sed -i -e s,$RPM_BUILD_ROOT,,g $RPM_BUILD_ROOT%{_bindir}/MakeNcl
|
||||||
|
|
||||||
@ -239,7 +246,6 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
%{_datadir}/ncarg/nclscripts/
|
%{_datadir}/ncarg/nclscripts/
|
||||||
%{_datadir}/ncarg/ngwww/
|
%{_datadir}/ncarg/ngwww/
|
||||||
%{_datadir}/ncarg/sysresfile/
|
%{_datadir}/ncarg/sysresfile/
|
||||||
%{_datadir}/ncarg/udunits/
|
|
||||||
%{_datadir}/ncarg/xapp/
|
%{_datadir}/ncarg/xapp/
|
||||||
%{_mandir}/man1/*.gz
|
%{_mandir}/man1/*.gz
|
||||||
%{_mandir}/man5/*.gz
|
%{_mandir}/man5/*.gz
|
||||||
@ -288,6 +294,9 @@ rm -rf $RPM_BUILD_ROOT
|
|||||||
|
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Nov 27 2008 - Orion Poplawski <orion@cora.nwra.com> - 5.0.0-13
|
||||||
|
- Enable udunits support add use system udunits.dat
|
||||||
|
|
||||||
* Thu Sep 11 2008 - Orion Poplawski <orion@cora.nwra.com> - 5.0.0-12
|
* Thu Sep 11 2008 - Orion Poplawski <orion@cora.nwra.com> - 5.0.0-12
|
||||||
- Rebuild for new libdap
|
- Rebuild for new libdap
|
||||||
- Fix netcdf include location
|
- Fix netcdf include location
|
||||||
|
Loading…
Reference in New Issue
Block a user