source: tags/se/lu/thep/affymetrix/0.7/Makefile @ 350

Last change on this file since 350 was 347, checked in by Jari Häkkinen, 15 years ago

Preparing 0.7 release of se.lu.thep.affymetrix

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 4.3 KB
Line 
1# $Id: Makefile 347 2007-06-27 20:01:41Z jari $
2
3# ======================================================================
4# Copyright (C) 2006 Jari Häkkinen
5# Copyright (C) 2007 Jari Häkkinen, Peter Johansson
6#
7# This file is part of BASEPlugIns - Non-core plug-ins for BASE,
8# BioArray Software Environment.
9# BASEPlugIns is available at http://baseplugins.thep.lu.se/
10# BASE is available at http://base.thep.lu.se/
11#
12# BASEPlugIns is free software; you can redistribute it and/or modify
13# it under the terms of the GNU General Public License as published by
14# the Free Software Foundation; either version 2 of the License, or
15# (at your option) any later version.
16#
17# BASEPlugIns is distributed in the hope that it will be useful, but
18# WITHOUT ANY WARRANTY; without even the implied warranty of
19# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
20# General Public License for more details.
21#
22# You should have received a copy of the GNU General Public License
23# along with this program; if not, write to the Free Software
24# Foundation, Inc., 59 Temple Place - Suite 330,
25# Boston, MA  02111-1307, USA.
26# ======================================================================
27#
28# Maintainer and advanced user information.
29#
30# 'make' will compile the source and create the jar file assuming that
31# the BASE application is located in BASEROOT defined below, and in
32# consequnce use BASECORE defined below as the BASE2Core.jar file.
33#
34# 'make BASEROOT=dir' can be used to point to where the BASE
35# application is installed. BASECORE and PLUGINDIR will be changed
36# accordingly.
37#
38# 'make BASECORE=/path/to/BASE2Core.jar' can be used to set the
39# BASE2Core.jar file independently of the BASE appication root.
40#
41# 'make RELPLUGINDIR=dir install' sets the plug-in installation
42# directory location relative to BASE root when installing the
43# plug-in. If the plug-dir location should be outside of the BASE
44# directory hierarchy use 'make PLUGINDIR=dir'.
45#
46# 'make PLUGINDIR=dir install' sets the plug-in installation directory
47# location independently of BASE root when installing the plug-in.
48#
49# 'make dist' with optional BASEROOT or BASECORE will create binary
50# distribution and source distribution packages with corresponding
51# md5sum files.
52#
53
54VERSION = 0.7
55
56TOPBUILDDIR = .build
57SUBDIR = se/lu/thep/affymetrix
58BUILDDIR = $(TOPBUILDDIR)/$(SUBDIR)
59
60# Prefix for where to install the plug-in. This is normally the path
61# to BASE
62BASEROOT ?= /usr/local/base
63
64# Location of BASE2Core.jar. This is usually
65# $(BASEROOT)/www/WEB-INF/lib/BASE2Core.jar
66BASECORE ?= $(BASEROOT)/www/WEB-INF/lib/BASE2Core.jar
67
68# The directory, relative to $(BASEROOT), where to install the plug-in
69RELPLUGINDIR ?= www/plugins/$(SUBDIR)
70PLUGINDIR ?= $(BASEROOT)/$(RELPLUGINDIR)
71
72JAVA = AbstractExternalBinaryPlugin.java Plier.java RMAExpress.java
73CLASS = $(JAVA:.java=.class)
74JAR  = affymetrix.jar
75
76# Files to include in binary distributions
77BINDISTFILES = AUTHORS ChangeLog COPYING INSTALL Makefile README $(JAR)
78# Binary package name
79BINPACKAGEFILE = base_affymetrix_plugin-$(VERSION)
80# Files to include in binary distributions
81SRCDISTFILES = AUTHORS ChangeLog COPYING INSTALL Makefile README $(JAVA)
82# Binary package name
83SRCPACKAGEFILE = $(BINPACKAGEFILE)-src
84
85all: $(JAR)
86
87clean:; @( rm -rf *.jar *.class *~ $(TOPBUILDDIR) \
88  $(BINPACKAGEFILE) $(BINPACKAGEFILE).tar.gz $(BINPACKAGEFILE).tar.gz.MD5 \
89  $(SRCPACKAGEFILE) $(SRCPACKAGEFILE).tar.gz $(SRCPACKAGEFILE).tar.gz.MD5 )
90
91dist: clean $(BINDISTFILES) $(SRCDISTFILES)
92  @echo Creating dist files
93  @mkdir $(BINPACKAGEFILE)
94  @cp -p $(BINDISTFILES) $(BINPACKAGEFILE)
95  @tar zcf $(BINPACKAGEFILE).tar.gz $(BINPACKAGEFILE)
96  @md5sum $(BINPACKAGEFILE).tar.gz > $(BINPACKAGEFILE).tar.gz.MD5
97  @mkdir $(SRCPACKAGEFILE)
98  @cp -p $(SRCDISTFILES) $(SRCPACKAGEFILE)
99  @tar zcf $(SRCPACKAGEFILE).tar.gz $(SRCPACKAGEFILE)
100  @md5sum $(SRCPACKAGEFILE).tar.gz > $(SRCPACKAGEFILE).tar.gz.MD5
101
102.PHONY: all clean dist install install-precompiled
103
104install: $(JAR) install-precompiled
105
106install-precompiled:
107  @install -d $(PLUGINDIR)
108  install -p $(JAR) $(PLUGINDIR)
109
110$(JAR): $(BUILDDIR) $(CLASS)
111  @echo Creating $(JAR)
112  @(cd $(TOPBUILDDIR) ; \
113    jar cf ../$(JAR) $(SUBDIR)/*.class)
114
115$(BUILDDIR)/%.java: %.java Makefile AbstractExternalBinaryPlugin.java
116  @sed "s/MAKESUBSTOFVERSIONNUMBER/$(VERSION)/" $< > $@
117
118%.class: $(BUILDDIR)/%.java
119  javac -cp $(BASECORE):$(TOPBUILDDIR)  $<
120
121$(BUILDDIR):
122  @install -d $@
123
Note: See TracBrowser for help on using the repository browser.