source: trunk/bindings/java/Make.tux @ 1822

Revision 211, 2.8 KB checked in by nexus, 9 years ago (diff)
  • Fixed a bug which caused foreign HDF-5's not to be read properly
  • Fixed a bug in NXgetnextentry which prevented reinitialising searches and nested searches.
  • Adapted the jnexus stuff to NAPI-2.0
  • Added the swig interface to NeXus to the source tree
  • Property svn:eol-style set to native
  • Property svn:keywords set to Author Date Id Revision
Line 
1#--------------------------------------------------------------------------
2# Makefile for the NeXus Java API. Builds both the required Java class
3# files and the shared library with the native methods.
4#
5# This version for Redhat Linux 6.2, which has an incompatible Make utility
6#
7# Mark Koennecke, October 2000
8#--------------------------------------------------------------------------
9.SUFFIXES:
10.SUFFIXES: .java .class .c .o
11
12###########################################################################
13#         C O N F I G U R A T I O N       S E C T I O N                   #
14###########################################################################
15# Where to find the HDF libraries: HDF4.1r3 is REQUIRED
16HDFROOT=$(SINQDIR)/linux
17
18#Where to find the napi C stuff
19NAPIROOT=$(SINQDIR)/linux
20
21# Where the Java binaries live
22JAVABIN=/usr/lib/IBMJava2-131/bin
23
24# The classpath for compiling java
25JCP=.:
26
27# The path to the include files for the jni-headers
28JINCLUDE= -I/usr/lib/IBMJava2-131/include
29
30# The C-compiler to use
31CC=gcc
32
33# Compiler flags to use for compiling
34CFLAGS= -g -c $(JINCLUDE) -DHDF4 -DHDF5 -I$(HDFROOT)/include -I$(NAPIROOT) \
35       -Inative
36
37#Compiler flags used for linking
38LFLAGS= -g -shared -L$(HDFROOT)/lib -L$(NAPIROOT)
39
40#Target location for the shared library
41SHLIB=bin/rh62/libjnexus.so
42
43###########################################################################
44#     END OF C O N F I G U R A T I O N       S E C T I O N                #
45#                  DO NOT TOUCH ANYTHING BELOW!                           #
46###########################################################################
47
48.java.class:
49        $(JAVABIN)/javac -g -classpath $(JCP) $*.java
50
51.c.o:
52        $(CC) $(CFLAGS) -o $*.o $*.c
53
54JOBJ=ncsa/hdf/hdflib/HDFException.class \
55     ncsa/hdf/hdflib/HDFJavaException.class \
56     ncsa/hdf/hdflib/HDFNotImplementedException.class \
57     ncsa/hdf/hdflib/HDFConstants.class \
58     ncsa/hdf/hdflib/HDFArray.class \
59     ncsa/hdf/hdflib/HDFNativeData.class \
60     neutron/nexus/NexusException.class \
61     neutron/nexus/NXlink.class \
62     neutron/nexus/NeXusFileInterface.class \
63     neutron/nexus/AttributeEntry.class \
64     neutron/nexus/NexusFile.class
65     
66
67COBJ=native/hdfnativeImp.o \
68     native/hdfexceptionImp.o \
69     native/handle.o \
70     native/NexusFile.o
71
72du40: all
73rh62: all
74
75
76all: jnexus.jar libjnexus.so test
77
78jnexus.jar: $(JOBJ)
79        - rm jnexus.jar
80        $(JAVABIN)/jar cvf jnexus.jar $(JOBJ) \
81          ncsa/hdf/hdflib/ArrayDescriptor.class
82
83libjnexus.so: $(COBJ)
84        $(CC) $(LFLAGS) -o $(SHLIB) $(COBJ) -lnexus \
85          -lmfhdf -ldf \
86          $(HDFROOT)/lib/libjpeg.a $(HDFROOT)/lib/libhdf5.a -lz -lm
87
88
89header: neutron/nexus/NexusFile.class
90        $(JAVABIN)/javah -jni -d native neutron.nexus.NexusFile
91
92test: test/TestJapi.class
93
94clean:
95        - rm neutron/nexus/*.class
96        - rm ncsa/hdf/hdflib/*.class
97        - rm native/*.o
98
99
Note: See TracBrowser for help on using the repository browser.