Skip to content

JogAmp/gluegen

This branch is 2 commits behind sgothel/gluegen:master.

Folders and files

NameName
Last commit message
Last commit date
Apr 20, 2011
Jan 14, 2023
Dec 2, 2023
Aug 12, 2023
Sep 16, 2012
Feb 4, 2024
Aug 16, 2019
Feb 4, 2024
Aug 5, 2023
Jul 4, 2023
Aug 8, 2023
Jan 15, 2023
Dec 10, 2016
Jun 18, 2023
May 8, 2010
Mar 26, 2011
Dec 30, 2019
Nov 20, 2009
Jul 4, 2023
Apr 7, 2010

Repository files navigation

GlueGen, Native Binding Generator for Java™

Original document location

Git Repository

This project's canonical repositories is hosted on JogAmp.

Overview

GlueGen is a compiler for function and data-structure declarations, generating Java™ and JNI C code offline at compile time and allows using native libraries within your Java™ application.

GlueGen also provides a comprehensive runtime library offering

  • Support for multi-arch and java code fat-jar deployment
    • Native library including JNI bundle handling and Jar file cache
    • Platform architecture information retrieval, ELF parser, alignment etc
  • Enhanced NIO buffer handling for pointer, arrays, DMA mapping etc
  • Network Uri RFC 2396, connection and resource handler to simplify asset loading
  • Bitstream, hash maps, ringbuffer, sha cumulator, reflection and threading utils
  • Abstract AudioFormat and AudioSink interfaces, concurrent locks .. and more

GlueGen's compiler reads ANSI C header files and separate configuration files which provide control over many aspects of the glue code generation. GlueGen uses a complete ANSI C parser and an internal representation (IR) capable of representing all C types to represent the APIs for which it generates interfaces. It has the ability to perform significant transformations on the IR before glue code emission.

GlueGen can produce native foreign function bindings to Java™ as well as map native data structures to be fully accessible from Java™ including potential calls to embedded function pointer.

GlueGen supports registering Java™ callback methods to receive asynchronous and off-thread native toolkit events, where a generated native callback function dispatches the events to Java™.

GlueGen also supports producing an OO-Style API mapping like JOGL's incremental OpenGL Profile API levels.

GlueGen is capable to bind low-level APIs such as the Java™ Native Interface (JNI) and the AWT Native Interface (JAWT) back up to the Java programming language.

Further, GlueGen supports generating JNI_OnLoad*(..) for dynamic and static libraries, also resolving off-thread JNIEnv* lookup.

GlueGen utilizes JCPP, migrated C preprocessor written in Java™.

GlueGen is used for the JogAmp projects JOAL, JOGL and JOCL.

GlueGen is part of the JogAmp project.

The JogAmp project needs funding and we offer commercial support!
Please contact Göthel Software (Jausoft).

License

See LICENSE.txt.

Documentation

Build Requirements

Check GlueGen's HowToBuild.

Directory Organization:

make/           Build-related files and the main build.xml
doc/            Documentation
jcpp/           JCPP (git sub-module), migrated C preprocessor written in Java
src/            The actual source for the JOAL APIs.
src/junit/      Unit tests
test/           Standalone manual tests
build/          (generated directory) Where the Jar and DLL files get built to
www/            JOAL project webpage files

Contact Us

History

Since roughly 2010, GlueGen development has been continued by individuals of the JogAmp community, see git log for details.

Packages

No packages published

Languages

  • Java 84.2%
  • GAP 5.5%
  • C 4.8%
  • Shell 2.3%
  • C++ 1.8%
  • Assembly 0.7%
  • Other 0.7%