aboutsummaryrefslogtreecommitdiff
path: root/iraf.cirred
diff options
context:
space:
mode:
authorJames Turner <jturner@gemini.edu>2016-12-07 13:16:51 -0500
committerJames Turner <jturner@gemini.edu>2016-12-07 13:16:51 -0500
commit1bf227afdf7d862fc26f9ed74887ef271f431fe2 (patch)
tree095395c7318737eff586cf1552a3c9aa8c1ca1ec /iraf.cirred
parent2bf58ad2e6d7c8cd96cc781d9dd9bdc0fa9fa85a (diff)
downloadastroconda-iraf-1bf227afdf7d862fc26f9ed74887ef271f431fe2.tar.gz
Add adccdrom, cfh12k & cirred IRAF packages.
Diffstat (limited to 'iraf.cirred')
-rw-r--r--iraf.cirred/ac.iraf.cirred.patch215
-rw-r--r--iraf.cirred/bld.bat2
-rw-r--r--iraf.cirred/build.sh11
-rw-r--r--iraf.cirred/meta.yaml28
-rw-r--r--iraf.cirred/post-link.sh3
-rw-r--r--iraf.cirred/pre-unlink.sh1
-rw-r--r--iraf.cirred/ur_extern.pkg5
-rw-r--r--iraf.cirred/ur_manifest3
-rw-r--r--iraf.cirred/ur_mkhelp_cmd1
-rw-r--r--iraf.cirred/ur_mkpkg_cmd6
-rw-r--r--iraf.cirred/ur_mkpkg_patterns1
11 files changed, 276 insertions, 0 deletions
diff --git a/iraf.cirred/ac.iraf.cirred.patch b/iraf.cirred/ac.iraf.cirred.patch
new file mode 100644
index 0000000..17bcfef
--- /dev/null
+++ b/iraf.cirred/ac.iraf.cirred.patch
@@ -0,0 +1,215 @@
+diff -Nur ../original/cirred.cl ./cirred.cl
+--- ../original/cirred.cl 2007-12-13 16:07:57.000000000 -0300
++++ ./cirred.cl 2016-05-03 13:32:13.000000000 -0300
+@@ -16,26 +16,28 @@
+
+ package cirred
+
+-set pkhome = "/uwe0/blum/IRAF/scripts/"
++# set cirred = "/uwe0/blum/IRAF/scripts/"
+
+-task clearim = pkhome$clearim.cl
+-task maskbad = pkhome$maskbad.cl
+-task osiris = pkhome$osiris.cl
+-task do_osiris = pkhome$do_osiris.cl
+-task atmo_cor = pkhome$atmo_cor.cl
+-task spec_comb = pkhome$spec_comb.cl
+-task extra = pkhome$extra.cl
+-task shift_comb = pkhome$shift_comb.cl
+-task sky_sub = pkhome$sky_sub.cl
+-task med = pkhome$med.cl
+-task do_wcs = pkhome$do_wcs.cl
+-task do_ccmap = pkhome$do_ccmap.cl
+-task irdiff = pkhome$irdiff.cl
+-
+-task $fixfits = $/uwe0/blum/IRAF/scripts/fixfits.e
+-task $fixfitsMEF = $/uwe0/blum/IRAF/scripts/fixfitsMEF.e
+-task $fixbad = $/uwe0/blum/IRAF/scripts/fixbad.e
+-task $calc_off = $/uwe0/blum/IRAF/scripts/calc_off.e
++task clearim = cirred$clearim.cl
++task maskbad = cirred$maskbad.cl
++task osiris = cirred$osiris.cl
++task do_osiris = cirred$do_osiris.cl
++task atmo_cor = cirred$atmo_cor.cl
++task spec_comb = cirred$spec_comb.cl
++task extra = cirred$extra.cl
++task shift_comb = cirred$shift_comb.cl
++task sky_sub = cirred$sky_sub.cl
++task med = cirred$med.cl
++task do_wcs = cirred$do_wcs.cl
++task do_ccmap = cirred$do_ccmap.cl
++task irdiff = cirred$irdiff.cl
++
++# JT: These build but I'm not sure whether they're working properly on 2.15.
++# In PyRAF On OSX, I get ('Not a legal IRAF pipe record', 32, 'Broken pipe').
++task $fixfits = cirred$bin/fixfits.e
++#task $fixfitsMEF = cirredbin/fixfitsMEF.e
++task $fixbad = cirred$bin/fixbad.e
++task $calc_off = cirred$bin/calc_off.e
+
+ keep
+
+diff -Nur ../original/cirred.par ./cirred.par
+--- ../original/cirred.par 1969-12-31 21:00:00.000000000 -0300
++++ ./cirred.par 2016-05-03 13:32:13.000000000 -0300
+@@ -0,0 +1 @@
++version,s,h,"29Sep2011UR"
+diff -Nur ../original/mkpkg ./mkpkg
+--- ../original/mkpkg 1969-12-31 21:00:00.000000000 -0300
++++ ./mkpkg 2016-05-11 20:25:28.000000000 -0300
+@@ -0,0 +1,155 @@
++# Make the cirred package (added for UR).
++
++update:
++ $call relink
++ $call install
++ ;
++
++# SUMMARY -- [UNIX] mkpkg summary: output a summary of the spooled mkpkg
++# output, omitting most of the mundane chatter. Used to scan large spool
++# files for errors.
++
++summary:
++ $ifeq (HOSTID, unix)
++ $ifndef (spool)
++ $set spool = spool
++ $endif
++ ! grep -v ':$$' spool | grep -v '^xc' | grep -v '^ar'\
++ | grep -v '^check file'
++ $else
++ $echo "mkpkg summary only available on a UNIX system"
++ $endif
++ ;
++
++relink:
++ $set LIBS="-limfort -lsys -lvops -los"
++ $ifeq (MACH, macosx) then
++ # Set this explicitly to suppress clang warnings on MacOS
++ # >=10.9 (as with HSI_FF etc.), since setting XC_FFLAGS for all
++ # the external package builds on 10.11 seems to trigger a bug
++ # somewhere (maybe in xc.c) that enables many other warnings.
++ $set OPTS="-/Wno-return-type"
++ $else
++ $set OPTS=""
++ $endif
++ $iffile(libcfitsio32.a) then
++ # Use UR cfitsio, copied from our variant build
++ $xc -h $(OPTS) fixfits.f libcfitsio32.a -o fixfits.e $(LIBS)
++ $else
++ # Use the bundled cfitsio binary if available
++ $ifeq(MACH, linux) then
++ $xc -h fixfits.f libcfitsio_lnx.a -o fixfits.e $(LIBS)
++ $else
++ $echo "No cfitsio on this platform: fixfits not built"
++ $endif
++ $endif
++ $xc -h $(OPTS) calc_off.f -o calc_off.e $(LIBS)
++ $xc -h $(OPTS) fixbad.f -o fixbad.e $(LIBS)
++ ;
++
++install:
++ $iffile(fixfits.e) then
++ $move fixfits.e cirred$bin/fixfits.e
++ $endif
++ $move fixbad.e cirred$bin/fixbad.e
++ $move calc_off.e cirred$bin/calc_off.e
++ ;
++
++
++# IRAF multiple architecture support.
++# ----------------------------------------
++
++arch: # show current float option
++showfloat:
++ $verbose off
++ !$(hlib)/mkfloat.csh
++ ;
++generic: # generic installation (no bin)
++ $ifnfile (bin.generic)
++ !mkdir bin.generic
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh generic -d $(DIRS)
++ ;
++
++freebsd: # install FreeBSD binaries
++ $ifnfile (bin.freebsd)
++ !mkdir bin.freebsd
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh freebsd -d $(DIRS)
++ ;
++linux: # install Slackwkare Linux binaries
++ $ifnfile (bin.linux)
++ !mkdir bin.linux
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh linux -d $(DIRS)
++ ;
++linux64: # install x86_64 binaries
++ $ifnfile (bin.linux64)
++ !mkdir bin.linux64
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh linux64 -d $(DIRS)
++ ;
++macosx: # install Mac OS X (PPC) binaries
++ $ifnfile (bin.macosx)
++ !mkdir bin.macosx
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh macosx -d $(DIRS)
++ ;
++macintel: # install Mac OS X (Intel) binaries
++ $ifnfile (bin.macintel)
++ !mkdir bin.macintel
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh macintel -d $(DIRS)
++ ;
++cygwin: # install Cygwin binaries
++ $ifnfile (bin.cygwin)
++ !mkdir bin.cygwin
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh cygwin -d $(DIRS)
++ ;
++redhat: # install Redhat Linux binaries
++ $ifnfile (bin.redhat)
++ !mkdir bin.redhat
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh redhat -d $(DIRS)
++ ;
++sparc: # install sparc binaries
++ $ifnfile (bin.sparc)
++ !mkdir bin.sparc
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh sparc -d $(DIRS)
++ ;
++ssun: # install Sun/Solaris binaries
++ $ifnfile (bin.ssun)
++ !mkdir bin.ssun
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh ssun -d $(DIRS)
++ ;
++sunos: # install SunOS (Solaris x86) binaries
++ $ifnfile (bin.sunos)
++ !mkdir bin.sunos
++ $endif
++ $verbose off
++ $set DIRS = "lib src"
++ !$(hlib)/mkfloat.csh sunos -d $(DIRS)
++ ;
diff --git a/iraf.cirred/bld.bat b/iraf.cirred/bld.bat
new file mode 100644
index 0000000..e1aca7a
--- /dev/null
+++ b/iraf.cirred/bld.bat
@@ -0,0 +1,2 @@
+echo Not supported on Windows
+exit 1
diff --git a/iraf.cirred/build.sh b/iraf.cirred/build.sh
new file mode 100644
index 0000000..7496e8e
--- /dev/null
+++ b/iraf.cirred/build.sh
@@ -0,0 +1,11 @@
+# Configure the environment for IRAF, since conda build appears not to do
+# "source activate" after installing dependencies (this would instead need to
+# eval $PREFIX/iraf/unix/hlib/setup directly if "--level" needs specifying):
+. setup_iraf.sh
+
+# Copy the cfitsio build dependency from IRAF:
+cp -p ${iraf}/bin/libcfitsio.a libcfitsio32.a || exit 1 # picked up by mkpkg
+
+# Build from source in envs/_build (using build script from astroconda-utils):
+ac_build_iraf_pkg
+
diff --git a/iraf.cirred/meta.yaml b/iraf.cirred/meta.yaml
new file mode 100644
index 0000000..3a44205
--- /dev/null
+++ b/iraf.cirred/meta.yaml
@@ -0,0 +1,28 @@
+about:
+ home: http://iraf.noao.edu/
+ license: IRAF MIT/X11 variant, US government notice
+ summary: CIRRED package for IRAF
+build:
+ binary_relocation: False
+ number: '0'
+ # These must be copied from astroconda-iraf-helpers, since conda disallows
+ # the post-install step from depending on other packages:
+ always_include_files:
+ - bin/ac_config_iraf_pkg
+ - bin/ac_update_extern_pkg
+package:
+ name: iraf.cirred
+ version: "2007_12_13"
+source:
+ fn: cirred-2007-12-13.tgz
+ url: http://astroconda-source:4440/cirred-2007-12-13.tgz
+ patches:
+ - ac.iraf.cirred.patch
+requirements:
+ build:
+ - astroconda-iraf-helpers
+ - iraf !=2.16.1,>=2.16.UR
+ run:
+ - iraf !=2.16.1,>=2.16.UR
+ - iraf.stsdas
+
diff --git a/iraf.cirred/post-link.sh b/iraf.cirred/post-link.sh
new file mode 100644
index 0000000..b659e2b
--- /dev/null
+++ b/iraf.cirred/post-link.sh
@@ -0,0 +1,3 @@
+# Call a common script that updates extern.pkg for the new IRAF package:
+
+"$PREFIX/bin/ac_config_iraf_pkg" cirred
diff --git a/iraf.cirred/pre-unlink.sh b/iraf.cirred/pre-unlink.sh
new file mode 100644
index 0000000..d81d34b
--- /dev/null
+++ b/iraf.cirred/pre-unlink.sh
@@ -0,0 +1 @@
+"$PREFIX/bin/ac_config_iraf_pkg" --remove cirred
diff --git a/iraf.cirred/ur_extern.pkg b/iraf.cirred/ur_extern.pkg
new file mode 100644
index 0000000..6fae86a
--- /dev/null
+++ b/iraf.cirred/ur_extern.pkg
@@ -0,0 +1,5 @@
+# http://www.ctio.noao.edu/instruments/ir_instruments/datared.html
+reset cirred = UR_VDIR
+task cirred.pkg = cirred$cirred.cl
+# cirred contains no helpdb
+
diff --git a/iraf.cirred/ur_manifest b/iraf.cirred/ur_manifest
new file mode 100644
index 0000000..db2afb7
--- /dev/null
+++ b/iraf.cirred/ur_manifest
@@ -0,0 +1,3 @@
+bin/calc_off.e
+bin/fixbad.e
+bin/fixfits.e
diff --git a/iraf.cirred/ur_mkhelp_cmd b/iraf.cirred/ur_mkhelp_cmd
new file mode 100644
index 0000000..73ec4ef
--- /dev/null
+++ b/iraf.cirred/ur_mkhelp_cmd
@@ -0,0 +1 @@
+echo "No help to build in cirred"
diff --git a/iraf.cirred/ur_mkpkg_cmd b/iraf.cirred/ur_mkpkg_cmd
new file mode 100644
index 0000000..cfd5f37
--- /dev/null
+++ b/iraf.cirred/ur_mkpkg_cmd
@@ -0,0 +1,6 @@
+# A mkpkg has been implemented for UR (in the cirred patch), but there's
+# no lib/ directory, so the usual mkpkg -p flag needs omitting here.
+# IRAF's libcfitsio32.a is copied here beforehand by build.sh.
+
+mkpkg update
+
diff --git a/iraf.cirred/ur_mkpkg_patterns b/iraf.cirred/ur_mkpkg_patterns
new file mode 100644
index 0000000..720a017
--- /dev/null
+++ b/iraf.cirred/ur_mkpkg_patterns
@@ -0,0 +1 @@
+^[ ]*MAIN calc_off:[ ]*$