File: Makefile.am

package info (click to toggle)
babel 0.10.2-1
  • links: PTS
  • area: contrib
  • in suites: sarge
  • size: 43,932 kB
  • ctags: 29,707
  • sloc: java: 74,695; ansic: 73,142; cpp: 40,649; sh: 18,411; f90: 10,062; fortran: 6,727; python: 6,406; makefile: 3,866; xml: 118; perl: 48
file content (74 lines) | stat: -rw-r--r-- 2,565 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
##
## File:        Makefile.am
## Package:     Babel CCA example
## Copyright:   (c) 2000-2001 The Regents of the University of California
## Revision:    $Revision: 4474 $
## Modified:    $Date: 2005-03-24 09:21:09 -0800 (Thu, 24 Mar 2005) $
## Description: automake makefile for Java CCA hello world driver
##

if SUPPORT_JAVA
check_SCRIPTS     = runJava.sh
check_LTLIBRARIES = libDriver.la
endif

BABELDIR   = $(top_builddir)
INCLUDEDIR = $(top_builddir)/runtime/sidl
LIBSIDL    = $(top_builddir)/runtime/sidl/libsidl.la
SIDLJAR    = $(top_builddir)/lib/sidl-@VERSION@.jar
PUREBABELGEN = $(STUBSRCS) $(IORHDRS) 
CLEANFILES = $(PUREBABELGEN) babel-stamp babel-temp stamp-installcheck 

nodist_libDriver_la_SOURCES      = $(PUREBABELGEN)
libDriver_la_LIBADD       = $(LIBSIDL) 
libDriver_la_LDFLAGS      = -no-undefined -rpath `pwd`/.libs -release @VERSION@

EXTRA_DIST = babel.make
AM_CPPFLAGS   = -I$(INCLUDEDIR) $(JNI_INCLUDES)

$(PUREBABELGEN) : babel-stamp
	@if test -f $@; then \
	  touch $@ ; \
	else \
	  $(MAKE) $(AM_MAKEFLAGS) babel-stamp ; \
	fi

if SUPPORT_CYGWIN
  CLASSPATH = `cygpath --path --windows "$(SIDLJAR)"`
else
  CLASSPATH = $(SIDLJAR)
endif
JAVAC_FLAGS = -g -d . -classpath "$(CLASSPATH)"

babel-stamp:
	@rm -f babel-temp
	@touch babel-temp
	$(SHELL) $(BABELDIR)/bin/babel --client=java \
	  --repository-path=../repository --suppress-timestamp \
	  decaf.Framework gov.cca.ComponentID gov.cca.Port gov.cca.ports.GoPort
	if test "X$(srcdir)" = "X."; then				    \
	  $(JAVAC) $(JAVAC_FLAGS) `find $(srcdir)			    \
	     -name .svn -prune -o					    \
	     -name CVS -prune -o -name SCCS -prune -o 			    \
             -name "*.java" -print`;					    \
	else								    \
	  $(JAVAC) $(JAVAC_FLAGS) `find $(srcdir) . 			    \
	     -name .svn -prune -o					    \
	     -name CVS -prune -o -name SCCS -prune -o			    \
             -name "*.java" -print`;					    \
	fi
	rm -f libDriver.scl
	echo "<?xml version=\"1.0\" ?>" > libDriver.scl
	echo "<scl>" >> libDriver.scl
	echo "  <library uri=\""`pwd`"/libDriver.la\" scope=\"local\" resolution=\"lazy\" >" >> libDriver.scl
	grep  __register $(STUBSRCS) /dev/null | awk 'BEGIN {FS=":"} { print $$1}' | sort -u | sed -e 's/_jniStub.c//g' -e 's/_/./g' | awk ' { printf "    <class name=\"%s\" desc=\"java\" />\n", $$1 }' >> libDriver.scl
	echo "  </library>" >> libDriver.scl
	echo "</scl>" >> libDriver.scl
	@mv babel-temp $@

clean-local:
	rm -f *.a *.so *.scl *.class 
	rm -rf decaf gov sidl 
	test "X$(srcdir)" = "X." || rm -f babel.make $(noinst_SCRIPTS)

include $(srcdir)/babel.make