summaryrefslogtreecommitdiff
path: root/classes/java-library.bbclass
blob: 8aecfef1b994381808c00745b9ed8aac64677fa7 (plain)
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
# Inherit this bbclass for each java recipe that builds a Java library (jar file[s]).
#
# It automatically adds important build dependencies, defines JPN (Java Package Name)
# a package named ${JPN} whose contents are those of ${datadir}/java (the jar location).
#
# The JPN is basically lib${PN}-java but takes care of the fact that ${PN} already
# starts with "lib" and/or ends with "-java". In case the "lib" prefix is part of
# your package's normal name (e.g. liberator) the guessing is wrong and you have
# to set JPN manually!

inherit java

def java_package_name(d):
  import bb;

  pre=""
  post=""

  pn = bb.data.getVar('PN', d, 1)
  if not pn.startswith("lib"):
    pre='lib'

  if not pn.endswith("-java"):
    post='-java'

  return pre + pn + post

JPN ?= "${@java_package_name(d)}"

DEPENDS_prepend = "virtual/javac-native fastjar-native "

PACKAGES = "${JPN}"

PACKAGE_ARCH_${JPN} = "all"

FILES_${JPN} = "${datadir_java}"

kages but note where c...Richard Purdie2 2006-01-07Convert CVSDATE -> SRCDATE. Also standardise cvs and svn PVs to x.x.x+cvsYYYY...Richard Purdie1 2005-09-12Opie 1.2.1:Holger Freyther2 2005-06-30import clean BK tree at cset 1.3670Koen Kooi7 2005-04-04Fix .inc file for opie-icon-reloadMatthias Hentges1 2005-03-26Merge nslu2-linux@nslu2-linux.bkbits.net:openembeddedg2@giantshoulder.com3 2005-02-23Merge bk://oe-devel.bkbits.net/openembeddednslu2-linux.adm@bkbits.net1 2005-02-23Merge bk://oe-devel.bkbits.net/openembeddednslu2-linux.adm@bkbits.net1 2004-12-09Merge oe-devel@oe-devel.bkbits.net:openembeddedChris Larson4