1# ===========================================================================
2#
3#                            PUBLIC DOMAIN NOTICE
4#               National Center for Biotechnology Information
5#
6#  This software/database is a "United States Government Work" under the
7#  terms of the United States Copyright Act.  It was written as part of
8#  the author's official duties as a United States Government employee and
9#  thus cannot be copyrighted.  This software/database is freely available
10#  to the public for use. The National Library of Medicine and the U.S.
11#  Government have not placed any restriction on its use or reproduction.
12#
13#  Although all reasonable efforts have been taken to ensure the accuracy
14#  and reliability of the software and data, the NLM and the U.S.
15#  Government do not and cannot warrant the performance or results that
16#  may be obtained by using this software or data. The NLM and the U.S.
17#  Government disclaim all warranties, express or implied, including
18#  warranties of performance, merchantability or fitness for any particular
19#  purpose.
20#
21#  Please cite the author in any work or product based on this material.
22#
23# ===========================================================================
24
25
26default: std
27
28TOP ?= $(abspath ../../../../../../..)
29MODULE = ngs/ngs-java/gov/nih/nlm/ncbi/ngs
30
31JARS = \
32	ngs-ncbi.jar
33
34ALL_TARGS = \
35	$(JARS)
36
37# default settings for java do not work here, override
38CLSPATH = $(TARGDIR)/ngs/ngs-java
39JAVASOURCEPATH = $(TOP)/ngs/ngs-java
40include $(TOP)/build/Makefile.env
41#$(warning JMAKE_CMD=$(JMAKE_CMD))
42
43#-------------------------------------------------------------------------------
44# outer targets
45#
46all std: $(ALL_TARGS)
47
48$(JARS): makejdirs
49	@ $(JMAKE_CMD) $(CLSPATH)/$@
50
51.PHONY: all std $(ALL_TARGS)
52
53#-------------------------------------------------------------------------------
54# clean
55#
56clean: stdjclean
57
58.PHONY: clean
59
60#-------------------------------------------------------------------------------
61# classes for ngs-ncbi
62#
63
64LIB_SRC =                          \
65	HttpException              \
66	HttpManager                \
67	LibManager                 \
68	LibPathIterator	           \
69	Logger      	           \
70	Manager      	           \
71	ReadCollectionItf          \
72	Refcount                   \
73	ReadGroupIteratorItf       \
74	ReadGroupItf               \
75	ReferenceIteratorItf       \
76	ReferenceItf               \
77	AlignmentItf               \
78	AlignmentIteratorItf       \
79	ReadItf                    \
80	ReadIteratorItf            \
81	PileupIteratorItf          \
82	PileupItf                  \
83	FragmentItf                \
84	PileupEventIteratorItf     \
85	PileupEventItf             \
86	TestyTheBear               \
87
88NGS_SRC =                      \
89    NGS                        \
90	$(LIB_SRC)
91
92#VARS = -Dvdb.System.loadLibrary=1
93#VARS = -Dvdb.log=FINEST
94#J=/net/pan1/sra-test/local/jdk1.7.0_51/bin/
95#JAVABITS=-d$(BITS)
96
97$(SRCDIR)/NGS.java: \
98	$(addprefix $(SRCDIR)/,$(addsuffix .java,$(LIB_SRC)))
99
100NGS_CLS = \
101	$(addsuffix .class,$(NGS_SRC))
102
103$(CLSPATH)/ngs-ncbi.jar: $(NGS_CLS)
104	( cd $(CLSPATH); jar -cf $@ `find ngs gov -name *.class` )
105
106#-------------------------------------------------------------------------------
107# manual integration test
108#
109test: $(CLSPATH)/ngs-ncbi.jar
110	cd $(CLSPATH); $(J)java $(JAVABITS) -classpath ngs-ncbi.jar $(VARS) \
111		-Djava.library.path=$(LIBDIR) gov.nih.nlm.ncbi.ngs.TestyTheBear
112