Changeset 794 for trunk/src/Makefile


Ignore:
Timestamp:
12/09/05 14:50:59 (19 years ago)
Author:
mar637
Message:

update from Release12

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/Makefile

    r717 r794  
    11TARGET   := /tmp/_asap.so
     2
     3
     4# the casa environment AIPSPATH has to be defined
     5CASAROOT  := $(word 1, $(AIPSPATH))
     6CASAARCH  := $(word 2, $(AIPSPATH))
     7CASAINC   := -I$(CASAROOT)/code/include -I$(CASAROOT)/code/casa
     8CASALIB   := $(CASAROOT)/$(CASAARCH)/lib
     9
     10
     11# the compiler
    212ifndef CXX
    313   CXX      := g++
    414endif
     15
     16# compiler flags
    517CXXFLAGS := -O3 -fPIC
    6 CXXFLAGS += -ansi
    7 CXXFLAGS += -pedantic -Wno-long-long
     18CXXFLAGS += -ansi -pedantic -Wno-long-long
    819CXXOPTS := -DAIPS_NO_TEMPLATE_SRC
    920
    10 CFITSIOROOT := /usr/local If aips++ is build with LFS you need to have
     21# darwin specific flags
     22ifeq "$(CASAARCH)" "darwin"
     23   CXXFLAGS := -O2 -DAIPS_DARWIN
     24   CXXFLAGS += -ansi -pedantic -Wno-long-long -Wno-long-double
     25endif
     26
     27
     28# cfitsio
     29CFITSIOROOT := /usr/local
     30# If aips++ is build with LFS you need to have
    1131# libcfitsio with lfs support
    12 CFITSIOLIB := /usr/local/lib/libcfitsio_lfs.a
    13 #CFITSIOINC := -I$(CFITSIOROOT)/include/cfitsio
     32CFITSIOINC := -I$(CFITSIOROOT)/include
     33CFITSIOLIB := $(CFITSIOROOT)/lib/libcfitsio_lfs.a
    1434#CFITSIOLIB := -L$(CFITSIOROOT) -lcfitsio
    1535
    16 
    17 CASAROOT  := $(word 1, $(AIPSPATH))
    18 CASAARCH  := $(word 2, $(AIPSPATH))
    19 CASAINC   := -I$(CASAROOT)/code/include -I$(CASAROOT)/code/casa/wcslib
    20 CASALIB   := $(CASAROOT)/$(CASAARCH)/lib
    21 
     36#rpfits
     37RPFITSROOT := /usr/local
     38RPFITSLIB := $(RPFITSROOT)/lib/librpfits.a
    2239
    2340# This assumes all casa libs are static only (*.a)
    2441# if not than there might by symbol resolution errors.
    2542CASAPPLIB := $(CASALIB)/version.o \
    26              -L$(CASALIB) -static \
     43             -L$(CASALIB) \
    2744             -latnf -limages -lms -lcomponents -lcoordinates \
    2845             -llattices -lfits -lmeasures -lmeasures_f \
    2946             -ltables -lscimath -lscimath_f -lcasa  \
    3047             $(CASALIB)/libwcs.a \
    31               -lrpfits $(CFITSIOLIB) -dy -llapack -lblas -lg2c
     48             $(RPFITSLIB) $(CFITSIOLIB) -lg2c -lstdc++
    3249
     50# darwin specific CASA flags
     51ifeq "$(CASAARCH)" "darwin"
     52   CASAPPLIB += -framework vecLib
     53else
     54   CASAPPLIB += -llapack -lblas
     55endif
     56
     57# the linker
    3358LD        := $(CXX)
     59
    3460LDFLAGS   := -shared -Wl$(TARGET) -s
     61ifeq "$(CASAARCH)" "darwin"
     62   LDFLAGS   := -dynamiclib -single_module
     63endif
    3564
     65# python only 2.3 has been tested
    3666PYVERSION := 2.3
    3767PYTHONROOT := /usr
     
    3969PYTHONLIB := -L$(PYTHONROOT)/lib -lpython$(PYVERSION)
    4070
    41 
     71# has to be build with same g++ version as casa
    4272BOOSTROOT := /usr
    4373BOOSTLIB  := -L$(BOOSTROOT)/lib -lboost_python
     
    4575
    4676
     77# DO NOT MODIFY AFTER THIS
    4778INCDIRS   := -I. $(CASAINC) $(BOOSTINC) $(PYTHONINC) $(CFITSIOINC)
    4879LIBS      := $(PYTHONLIB)  $(BOOSTLIB) $(CASAPPLIB)
Note: See TracChangeset for help on using the changeset viewer.