- Revenera Community
- :
- FlexNet Publisher
- :
- FlexNet Publisher Knowledge Base
- :
- Enabling Native HostID support with Java Based FNP applications.
- Mark as New
- Mark as Read
- Subscribe
- Printer Friendly Page
- Report Inappropriate Content
Enabling Native HostID support with Java Based FNP applications.
Enabling Native HostID support with Java Based FNP applications.
Native hostids are provided transparently via Java Native Interface (JNI) hostid integration, and can be enabled with a single method invocation. By shipping platform-dependent native code, it is simple to use the non-Java FlexNet Publisher Licensing Toolkit code to provide hostid capability to FlexEnabled Java products.
The following sections outline how to implement native hostid support.
Task To implement native hostid support on Windows platforms:
1. Build the FlexNet Publisher Licensing Toolkit. Refer to the Development Environment Guide for details on building the kit.
2. Build lmgr11.dll in the FlexNet Publisher Licensing Toolkit. To do so, enter the following from the <sdk_platform> directory in your toolkit installation:
nmake -f makefile DLL=1 to build lmgr11.dll without dongle support
or
nmake -f makefile DLL=1 DONGLE=1 to build lmgr11.dll with dongle support
This client DLL contains the hostid-object code that you must ship with your product.
3. In the Java virtual machine’s $PATH environment variable, include the path to the folder containing lmgr11.dll. This is how the Java Virtual Machine locates code invoked through JNI.
4. In the Java source code, invoke the useNativeHostIds method on any VendorInfo subclass instances that are created by the application code.
Task To implement native hostid support on UNIX platforms:
1. Build the FlexNet Publisher Licensing Toolkit. Refer to the Development Environment Guide for details on building the kit.
2. Build liblmgr11.so in the FlexNet Publisher Licensing Toolkit. To do so, enter the following from the <sdk_platform> directory in your toolkit installation:
make shared_object
This shared object contains the C functions required to support Java native hostids.
3. Set the LD_LIBRARY_PATH system environment variable to include the path to liblmgr11.so.
4. In the Java source code, invoke the useNativeHostIds method on any VendorInfo subclass instances that are created by the application code. See the online API documentation for details on the VendorInfo.useNativeHostids method.
=====================================================================================================
Talking exclusively in the terms of BasicExample.Java file:
|