changeset 3980:9f7e9b053041

of-nan: add Nan 2.8.0 package * Makefile.in: add of-nan to OCTAVE_FORGE_PACKAGES * build_packages.m: add nan-2.8.0 install * dist-files.mk: add of-nan-1-cross-fixes.patch, of-nan.m * index.html: add of-nan package * of-nan.mk: new file * of-nan-1-cross-fixes.patch: new file
author John Donoghue
date Tue, 30 Jun 2015 13:41:41 -0400
parents 246d007d1b42
children f1cc0bdd57b6
files Makefile.in build_packages.m dist-files.mk index.html src/of-nan-1-cross-fixes.patch src/of-nan.mk
diffstat 6 files changed, 52 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/Makefile.in	Mon Jun 22 12:37:08 2015 -0400
+++ b/Makefile.in	Tue Jun 30 13:41:41 2015 -0400
@@ -429,7 +429,7 @@
 endif
 
 OCTAVE_FORGE_BASE_URL := 'http://sourceforge.net/projects/octave/files/Octave Forge Packages/Individual Package Releases'
-OCTAVE_FORGE_PACKAGES := $(addprefix of-,miscellaneous struct optim specfun general signal communications image io statistics control geometry windows linear-algebra sockets zenity data-smoothing fuzzy-logic-toolkit quaternion fits fl-core tsa dicom netcdf ltfat database instrument-control generate_html nurbs strings octcdf financial stk splines dataframe lssa queueing ga odepkg interval)
+OCTAVE_FORGE_PACKAGES := $(addprefix of-,miscellaneous struct optim specfun general signal communications image io statistics control geometry windows linear-algebra sockets zenity data-smoothing fuzzy-logic-toolkit quaternion fits fl-core tsa dicom netcdf ltfat database instrument-control generate_html nurbs strings octcdf financial stk splines dataframe lssa queueing ga odepkg interval nan)
 # get ALL deps for all of- packages, regardless of whethe building the actual forge package in the installer
 OCTAVE_FORGE_DEPS:= $(sort $(foreach p,$(wildcard $(TOP_DIR)/src/of-*.mk),$(shell $(SED) -n 's/.*_DEPS.*:=\(.*\)/\1/p' $p)))
 
--- a/build_packages.m	Mon Jun 22 12:37:08 2015 -0400
+++ b/build_packages.m	Tue Jun 30 13:41:41 2015 -0400
@@ -60,4 +60,5 @@
 try_install strings-1.2.0.tar.gz
 try_install ga-0.10.0.tar.gz
 try_install interval-1.0.0.tar.gz
+try_install nan-2.8.0.tar.gz
 
--- a/dist-files.mk	Mon Jun 22 12:37:08 2015 -0400
+++ b/dist-files.mk	Tue Jun 30 13:41:41 2015 -0400
@@ -478,6 +478,8 @@
   of-ltfat.mk \
   of-miscellaneous-1-fixes.patch \
   of-miscellaneous.mk \
+  of-nan-1-cross-fixes.patch \
+  of-nan.mk \
   of-netcdf.mk \
   of-nurbs-1-fixes.patch \
   of-nurbs.mk \
--- a/index.html	Mon Jun 22 12:37:08 2015 -0400
+++ b/index.html	Tue Jun 30 13:41:41 2015 -0400
@@ -1938,6 +1938,10 @@
         <td class="website"><a href="http://octave.sf.net/">Octave Forge miscellaneous package</a></td>
     </tr>
     <tr>
+        <td class="package">of-nan</td>
+        <td class="website"><a href="http://octave.sf.net/">Octave Forge NaN package</a></td>
+    </tr>
+    <tr>
         <td class="package">of-netcdf</td>
         <td class="website"><a href="http://octave.sf.net/">Octave Forge netcdf package</a></td>
     </tr>
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/of-nan-1-cross-fixes.patch	Tue Jun 30 13:41:41 2015 -0400
@@ -0,0 +1,22 @@
+diff -ur NaN.orig/src/Makefile NaN/src/Makefile
+--- NaN.orig/src/Makefile	2015-06-30 13:30:25.348544831 -0400
++++ NaN/src/Makefile	2015-06-30 13:35:18.600346663 -0400
+@@ -31,13 +31,15 @@
+ # Instead of building "mex shortpath.c" and "mex uigetpath.c", I used empty m-functions within argout=argin; 
+ ####################################################
+ MKOCTFILE ?= mkoctfile$(OCTAVE_VERSION)
+-CC      = gcc
+-CXX     = g++
++OCTAVE_CONFIG ?= octave-config
++CC      = $(shell $(MKOCTFILE) -p CC)
++CXX     = $(shell $(MKOCTFILE) -p CXX)
+ CFLAGS 	= -fopenmp -Wall -Wextra -Wconversion -O2
+ OCTMEX	= $(MKOCTFILE) --mex
+ RM      = rm
+ 
+-ifneq ($(OS),Windows_NT)
++HOST_TYPE := $(shell $(OCTAVE_CONFIG) -p CANONICAL_HOST_TYPE))
++ifeq (,$(findstring mingw,$(HOST_TYPE)))
+ CFLAGS      += -fPIC
+ endif
+ 
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/src/of-nan.mk	Tue Jun 30 13:41:41 2015 -0400
@@ -0,0 +1,22 @@
+# This file is part of MXE.
+# See index.html for further information.
+
+PKG             := of-nan
+$(PKG)_IGNORE   :=
+$(PKG)_VERSION  := 2.8.0
+$(PKG)_CHECKSUM := 308067242050f21e67c7b9a482705a710531eb82
+$(PKG)_REMOTE_SUBDIR := 
+$(PKG)_SUBDIR   := NaN
+$(PKG)_FILE     := nan-$($(PKG)_VERSION).tar.gz
+$(PKG)_URL      := '$(OCTAVE_FORGE_BASE_URL)/$($(PKG)_FILE)/download'
+$(PKG)_DEPS     := 
+
+define $(PKG)_UPDATE
+    $(WGET) -q -O- 'http://$(SOURCEFORGE_MIRROR)/projects/octave/files/Octave%20Forge%20Packages/Individual%20Package%20Releases/' | \
+    $(SED) -n 's,.*title="nan-\([0-9][^"]*\).tar.gz".*,\1,p' | \
+    head -1
+endef
+
+define $(PKG)_BUILD
+    $(OCTAVE_FORGE_PKG_BUILD)
+endef