Annotation of /branches/R11-stable/include/java.sminc
Parent Directory | Revision Log
Revision 9669 -
(hide annotations)
(download)
Wed Jan 4 13:12:17 2012 UTC (12 years, 10 months ago) by niro
Original Path: branches/magellan-next/include/java.sminc
File size: 915 byte(s)
Wed Jan 4 13:12:17 2012 UTC (12 years, 10 months ago) by niro
Original Path: branches/magellan-next/include/java.sminc
File size: 915 byte(s)
-fixed minstalljar()
1 | niro | 9644 | # $Id$ |
2 | |||
3 | sminclude mtools | ||
4 | |||
5 | niro | 9667 | JAVA_CLASSPATH_DIR="/usr/share/java" |
6 | |||
7 | niro | 9644 | jar-path-from-classpath() |
8 | { | ||
9 | local jar="$1" | ||
10 | local i | ||
11 | |||
12 | for i in ${CLASSPATH//:/ } | ||
13 | do | ||
14 | case ${i} in | ||
15 | *${jar}) echo ${i};; | ||
16 | esac | ||
17 | done | ||
18 | } | ||
19 | |||
20 | niro | 9645 | mclasspathinit() |
21 | { | ||
22 | minstalldir /etc/env.d || die | ||
23 | |||
24 | # classpath env | ||
25 | MCONFIG="/etc/env.d/22java-app-${PNAME}" | ||
26 | mclearconfig || die | ||
27 | } | ||
28 | |||
29 | niro | 9667 | minstalljar-classpath() |
30 | niro | 9644 | { |
31 | local files | ||
32 | local jar | ||
33 | |||
34 | files="$@" | ||
35 | |||
36 | # needed directories | ||
37 | minstalldir /etc/env.d || die | ||
38 | minstalldir /usr/share/${PNAME}-${PVER}/lib || die | ||
39 | |||
40 | # classpath env | ||
41 | MCONFIG="/etc/env.d/22java-app-${PNAME}" | ||
42 | |||
43 | for jar in ${files} | ||
44 | do | ||
45 | minstallfile ${jar} /usr/share/${PNAME}-${PVER}/lib || die | ||
46 | maddconfig "CLASSPATH=/usr/share/${PNAME}-${PVER}/lib/${jar}" || die | ||
47 | done | ||
48 | } | ||
49 | niro | 9667 | |
50 | minstalljar() | ||
51 | { | ||
52 | local files | ||
53 | local jar | ||
54 | |||
55 | files="$@" | ||
56 | |||
57 | niro | 9669 | minstalldir ${JAVA_CLASSPATH_DIR} || die |
58 | niro | 9667 | for jar in ${files} |
59 | do | ||
60 | minstallfile ${jar} ${JAVA_CLASSPATH_DIR} || die | ||
61 | done | ||
62 | } |