javago

command module
v0.0.0-...-b3de8e1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 11, 2017 License: MIT Imports: 8 Imported by: 0

README

javago

Java wrapper code generator for Go.

How to use

Install jnigo javago

go get github.com/juntaki/jnigo
go get github.com/juntaki/javago

Run command

$ javago -h
NAME:
   javago - Java binding generator for Go

USAGE:
   javago [global options] command [command options] [arguments...]

VERSION:
   0.0.0

COMMANDS:
     help, h  Shows a list of commands or help for one command

GLOBAL OPTIONS:
   --classpath value  Specifies the path the javap command uses to look up classes. (default: "*:.")
   --classfile value  classfile
   --help, -h         show help
   --version, -v      print the version

e.g. generate java.lang.Math wrapper code. Generated file is in sample directory in this repository.

$ javago --classfile java.lang.Math
$ ls java
java.lang.Math.go

Run your app with javago wrapper

Don't forget to add libjvm.so's directory to LD_LIBRARY_PATH.

for debian/ubuntu
export LD_LIBRARY_PATH=/usr/lib/jvm/default-java/jre/lib/amd64/server
export CLASSPATH="." # add your classpath
go build
./yourapp
for mac
export JAVA_HOME=`/usr/libexec/java_home` 
export LD_LIBRARY_PATH=$JAVA_HOME/jre/lib/server/
export CLASSPATH="."
go build
./yourapp

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL