[ncl/el6] Don't link against librx, was causing memory corruption Compile with -fno-strict-aliasing for now
Orion Poplawski
orion at fedoraproject.org
Mon Jul 16 22:23:51 UTC 2012
commit f36aa4fc7901500a0110451524b245344bf5e0dd
Author: Orion Poplawski <orion at nwra.com>
Date: Mon Jul 16 16:15:48 2012 -0600
Don't link against librx, was causing memory corruption
Compile with -fno-strict-aliasing for now
ncl-5.2.0-libs.patch | 24 ------------------------
ncl-libs.patch | 24 ++++++++++++++++++++++++
ncl.spec | 14 +++++++++-----
3 files changed, 33 insertions(+), 29 deletions(-)
---
diff --git a/ncl-libs.patch b/ncl-libs.patch
new file mode 100644
index 0000000..4d2cbd7
--- /dev/null
+++ b/ncl-libs.patch
@@ -0,0 +1,24 @@
+diff -up ncl_ncarg-6.0.0/ncarview/src/bin/ictrans/yMakefile.libs ncl_ncarg-6.0.0/ncarview/src/bin/ictrans/yMakefile
+--- ncl_ncarg-6.0.0/ncarview/src/bin/ictrans/yMakefile.libs 2011-05-27 12:53:51.000000000 -0600
++++ ncl_ncarg-6.0.0/ncarview/src/bin/ictrans/yMakefile 2012-07-16 15:29:08.141021676 -0600
+@@ -29,6 +29,8 @@ DEP_LIBS = $(DEPICTRANSLIB) $(DEPCTRANSL
+
+ #ifdef IRIX
+ MORE_LIBS = -lmalloc
++#else
++MORE_LIBS = -lm
+ #endif
+
+ EXTRA_LIBS = $(X11LIBS) $(SUNLIBS) $(NETCDFLIB) $(HDFLIB) $(CTOFLIBS)
+diff -up ncl_ncarg-6.0.0/ni/src/ncl/yMakefile.libs ncl_ncarg-6.0.0/ni/src/ncl/yMakefile
+--- ncl_ncarg-6.0.0/ni/src/ncl/yMakefile.libs 2011-05-27 12:53:25.000000000 -0600
++++ ncl_ncarg-6.0.0/ni/src/ncl/yMakefile 2012-07-16 15:55:03.393194314 -0600
+@@ -141,7 +141,7 @@ DODS_LIBS = -lnc-dap -ldap -ldapclient -
+ #elif defined(Darwin)
+ DODS_LIBS = -lnc-dap -ldap -ldapclient -lcurl -lxml2 -lpthread -lssl
+ #elif defined(linux)
+-DODS_LIBS = -lnc-dap -ldap -ldapclient -lcurl -lrx -lxml2 -lpthread -lidn -ldl
++DODS_LIBS = -lcurl -lpthread
+ #else
+ DODS_LIBS = -lnc-dap -ldap -ldapclient -lcurl -lrx -lxml2 -lpthread -lssl
+ #endif
diff --git a/ncl.spec b/ncl.spec
index d824b10..c08ae86 100644
--- a/ncl.spec
+++ b/ncl.spec
@@ -1,6 +1,6 @@
Name: ncl
Version: 6.0.0
-Release: 2%{?dist}
+Release: 3%{?dist}
Summary: NCAR Command Language and NCAR Graphics
Group: Applications/Engineering
@@ -29,8 +29,8 @@ Source3: ncarg.sh
Patch0: ncl-5.1.0-paths.patch
Patch1: ncarg-4.4.1-deps.patch
Patch2: ncl-5.1.0-ppc64.patch
-# Add needed -lm to ictrans build, remove unneeded -lidn -ldl from ncl
-Patch3: ncl-5.2.0-libs.patch
+# Add needed -lm to ictrans build, remove unneeded -lrx -lidn -ldl from ncl
+Patch3: ncl-libs.patch
# Patch to fix xwd driver on 64-bit (bug 839707)
Patch4: ncl-xwd.patch
Patch7: ncl-5.0.0-atlas.patch
@@ -50,7 +50,7 @@ BuildRequires: /bin/csh, gcc-gfortran, netcdf-devel
BuildRequires: cairo-devel
BuildRequires: gdal-devel
BuildRequires: hdf-static, hdf-devel >= 4.2r2, libjpeg-devel
-BuildRequires: g2clib-static, librx-devel, atlas-devel
+BuildRequires: g2clib-static, atlas-devel
# imake needed for makedepend
BuildRequires: imake, libXt-devel, libXaw-devel, libXext-devel, libXpm-devel
BuildRequires: byacc, flex
@@ -176,7 +176,7 @@ sed -i -e 's;load "\$NCARG_ROOT/lib/ncarg/nclex\([^ ;]*\);loadscript(ncargpath("
#make Build CCOPTIONS="$RPM_OPT_FLAGS -fPIC -Werror-implicit-function-declaration" F77=gfortran F77_LD=gfortran\
-make Build CCOPTIONS="$RPM_OPT_FLAGS -fPIC" F77=gfortran F77_LD=gfortran\
+make Build CCOPTIONS="$RPM_OPT_FLAGS -fPIC -fno-strict-aliasing" F77=gfortran F77_LD=gfortran\
CTOFLIBS="-lgfortran" FCOPTIONS="$RPM_OPT_FLAGS -fPIC -fno-second-underscore -fno-range-check" \
COPT= FOPT=
@@ -342,6 +342,10 @@ rm -rf $RPM_BUILD_ROOT
%changelog
+* Mon Jul 17 2012 Orion Poplawski <orion at cora.nwra.com> - 6.0.0-3
+- Don't link against librx, was causing memory corruption
+- Compile with -fno-strict-aliasing for now
+
* Fri Jul 13 2012 Orion Poplawski <orion at cora.nwra.com> - 6.0.0-2
- Add patch to fix xwd driver on 64-bit (bug 839707)
More information about the scm-commits
mailing list