source: plugins/base1/se.lu.thep.wenni/trunk/base/base2/Makefile.am @ 853

Last change on this file since 853 was 853, checked in by Jari Häkkinen, 14 years ago

Fixes #152. Added custom target 'install-plugin' that parallels 'install'.

  • Property svn:eol-style set to native
  • Property svn:keywords set to Id
File size: 2.0 KB
Line 
1## Process this file with automake to produce Makefile.in
2##
3## $Id: Makefile.am 853 2008-12-01 22:59:25Z jari $
4
5# Copyright (C) 2007 Peter Johansson
6# Copyright (C) 2008 Jari Häkkinen
7#
8# This file is part of WeNNI,
9# http://baseplugins.thep.lu.se/wiki/se.lu.thep.WeNNI
10#
11# WeNNI is free software; you can redistribute it and/or modify it
12# under the terms of the GNU General Public License as published by the
13# Free Software Foundation; either version 3 of the License, or (at
14# your option) any later version.
15#
16# WeNNI is distributed in the hope that it will be useful, but WITHOUT
17# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18# FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
19# for more details.
20#
21# You should have received a copy of the GNU General Public License
22# along with WeNNI. If not, see <http://www.gnu.org/licenses/>.
23
24TOPBUILDDIR = .build
25SUBDIR = se/lu/thep/wenni
26BUILDDIR = $(TOPBUILDDIR)/$(SUBDIR)
27
28JAVA = WeNNI.java
29CLASS = $(JAVA:.java=.class)
30JAR  = WeNNI.jar
31
32
33all-local: $(JAR)
34
35clean-local:; @( rm -rf *.jar *.class *~ $(TOPBUILDDIR))
36
37distclean-local: clean-local
38  @( rm -rf $(PLUGINutilities) $(PLUGINutilities).tgz )
39
40install-exec-local: $(JAR)
41  @$(NORMAL_INSTALL)
42  test -z "$(bindir)" || $(MKDIR_P) "$(bindir)"
43  $(INSTALL) "$(JAR)" "$(bindir)"
44  $(INSTALL) "$(PLUGINutilities)/$(PLUGINutilities).jar" "$(bindir)"
45
46install-plugin: $(JAR)
47  @$(NORMAL_INSTALL)
48  test -z "$(PLUGINDIR)" || $(MKDIR_P) "$(PLUGINDIR)"
49  $(INSTALL) "$(JAR)" "$(PLUGINDIR)"
50  $(INSTALL) "$(PLUGINutilities)/$(PLUGINutilities).jar" "$(PLUGINDIR)"
51
52$(JAR): $(BUILDDIR) $(PLUGINutilities) $(CLASS)
53  @echo Creating $(JAR)
54  @(cd $(TOPBUILDDIR) ; \
55    jar cf ../$(JAR) $(SUBDIR)/*.class)
56
57$(BUILDDIR)/$(JAVA): $(srcdir)/$(JAVA) Makefile
58  @$(SED) "s/MAKESUBSTOFVERSIONNUMBER/$(VERSION)/" $< > $@
59
60$(CLASS): $(BUILDDIR)/$(JAVA)
61  javac -cp $(JAVACFLAGS):$(TOPBUILDDIR)  $<
62
63$(BUILDDIR):
64  @$(MKDIR_P) $@
65
66$(PLUGINutilities): $(PLUGINutilities).tgz
67  tar zxpf $<
68
69$(PLUGINutilities).tgz:
70  wget -O $@ $(PLUGINutilitiesURL)
Note: See TracBrowser for help on using the repository browser.