source: branches/alma/Makefile@ 1558

Last change on this file since 1558 was 1455, checked in by Kana Sugimoto, 16 years ago

New Development: No

JIRA Issue: No

Ready to Release: Yes

Interface Changes: No

What Interface Changed:

Test Programs:

Put in Release Notes: No

Description: This committion is on behalf of Takeshi.

Updated environmental variable and library pathes in Makefiles
for CASA+CASACore software.
Changed include files in Template.cpp for CASA+CASACore software.


File size: 2.2 KB
Line 
1### Notice:
2### This Makefile assumes CASA+CASACore enviroment.
3### For who wants to build ASAP with older CASA without CASACore
4### environment, replace $(CASAPATH) with $(AIPSPATH).
5PREFIX := /opt/casa/darwin
6#PREFIX := /export/home/minor/casa/active/linux_gnu
7PYDIR := $(PREFIX)/python/2.5
8
9ifndef ASAPROOT
10 ASAPROOT := $(shell pwd)
11endif
12
13#PY := $(wildcard python/*.py)
14PY := $(wildcard python/*.py python/svninfo.txt)
15LIBS := /tmp/_asap.so
16BINS := bin/asap
17
18CASAROOT := $(word 1, $(CASAPATH))
19PLATFORM := $(word 2, $(CASAPATH))
20DISTDIR := asap_$(PLATFORM)
21
22all: module #doc
23
24module:
25 @cd $(ASAPROOT)/src; make
26 @if ( test -f getsvnrev.sh ) ; then /bin/bash getsvnrev.sh ; fi
27
28doc:
29 @cd $(ASAPROOT)/doc; make
30
31
32install:
33 @if ( test ! -d $(PYDIR)/asap ) ; then mkdir -p $(PYDIR)/asap ; fi
34 @if ( test ! -d $(PREFIX)/bin ) ; then mkdir -p $(PREFIX)/bin ; fi
35 @for file in $(LIBS) ; do cp -f $$file $(PYDIR)/asap ; done
36 @for file in $(BINS) ; do cp -f $$file $(PREFIX)/bin ; done
37 @for file in $(PY) ; do cp -f $$file $(PYDIR)/asap ; done
38 @if ( test ! -d $(PREFIX)/share/asap ) ; then mkdir -p $(PREFIX)/share/asap ; fi
39 @cp -f share/ipythonrc-asap $(PREFIX)/share/asap/
40 @echo "Successfully installed asap module to" $(PYDIR)
41
42clean:
43 @cd $(ASAPROOT)/src; make clean
44 @cd $(ASAPROOT)/doc; make clean
45
46datadist:
47 @echo "Generating ASAP data archive from aips++ installation..."
48 @cd $(CASAROOT); tar cfj $(ASAPROOT)/$(DISTDIR)/share/data.tar.bz2 data/ephemerides data/geodetic
49 @echo "...done."
50
51
52dist: module doc
53 @cd $(ASAPROOT)
54 @if ( test -d $(DISTDIR) ) ; then rm -rf $(DISTDIR) ; fi
55 @mkdir $(DISTDIR)
56 @mkdir $(DISTDIR)/build $(DISTDIR)/bin $(DISTDIR)/share
57 @for file in $(LIBS) ; do cp -f $$file $(DISTDIR)/build/ ; done
58 @for file in $(PY) ; do cp -f $$file $(DISTDIR)/build/ ; done
59 @for file in $(BINS) ; do cp -f $$file $(DISTDIR)/bin/ ; done
60 @cp -f share/ipythonrc-asap $(DISTDIR)/share/
61 make datadist
62 @cp -f doc/README $(DISTDIR)/
63 @cp -f doc/CHANGELOG $(DISTDIR)/
64 @cp -f bin/install.sh $(DISTDIR)/bin/
65 @echo "Creating compressed archive..."
66 @tar jcf $(DISTDIR).tar.bz2 $(DISTDIR)
67 @rm -rf $(DISTDIR)/
68 @echo "Successfully created binary package" $(DISTDIR).tar.bz2
69
70.PHONY: install clean
Note: See TracBrowser for help on using the repository browser.