SUMMARY="A Japanese input method add-on"
DESCRIPTION="Canna (CannaIM) is a Japanese input method add-on. \
It is based a client-server based Kana-Kanji conversion system \"Canna\"."
HOMEPAGE="http://canna.sourceforge.jp/"
LICENSE="MIT"
COPYRIGHT="
	1999 M.Kawamura
	1992 NEC Corporation, Tokyo, Japan.
	"
srcrev="82b97486e551f7ce15ad908b478f33a0a8611c8b"
SOURCE_URI="https://github.com/mt819/CannaIM/archive/$srcrev.zip"
SOURCE_FILENAME="$portName-$srcrev.tar.gz"
SOURCE_DIR="CannaIM-$srcrev"
CHECKSUM_SHA256="42b261ba65f77e41ef7507befa769fe7637459d2a9059fb3cad5ff3a7f917c5a"
REVISION="1"
ARCHITECTURES="x86_gcc2 x86 x86_64"

PROVIDES="
	canna = $portVersion
	addon:canna = $portVersion
	"

REQUIRES="
	haiku
	"

BUILD_REQUIRES="
	"

BUILD_PREREQUIRES="
	haiku_devel
	cmd:gcc
	cmd:jam
	"

USER_SETTINGS_FILES="
	settings/Canna directory
	"

BUILD()
{
	jam -q $jobArgs
}

INSTALL()
{
	CannaDir=$addOnsDir/input_server/methods
	mkdir -p $CannaDir
	cp -a generated/distro/canna $CannaDir

	CannaDataDir=$dataDir/Canna
	mkdir -p $CannaDataDir
	cp -a data/default $CannaDataDir
	cp -a data/dic $CannaDataDir
}
