When you are deploying a Luciad portfolio-based application, you are required to obfuscate the Luciad portfolio libraries with ProGuard.
As this is an intricate process, you can already take some precautions to prevent potential glitches before you start obfuscating. If you still run into problems despite those precautions, you can find a couple of suggestions for solutions in this article as well.
Obfuscation is quite a complex process that involves re-writing the class files. We try to make the process as hassle-free as possible by shipping a tested sample Proguard configuration for you to use.
By respecting these two simple rules, you can prevent most obfuscation-related problems:
Always use the latest version of ProGuard.
When you upgrade to a newer version of your Luciad portfolio product, make sure to upgrade your ProGuard configuration as well. Take notice of any changes made to the product’s sample configuration.
If you still encounter problems during or after obfuscation, check if the issue can be attributed to one of the causes below before you contact the Luciad Support Desk Services.
Check the solutions to some of the possible issues with ProGuard obfuscation.
Get more information
Do not use the
The log of warnings will also be of help if you still have to get in touch with the Luciad Support Desk Services.
You may have incorrectly split
Make sure that:
All Luciad JARs (the JARs with an
lcd_prefix) and your application JARs are marked as
All third-party JARs are marked as
jce.jarmust both be specified as
This is most likely caused by turning off the pre-verification option in Proguard. As of Java 7, pre-verification is required or your application will not run.
Make sure that the
-dontpreverifyoption doesn’t appear anywhere in your ProGuard configuration.
Errors caused by ProGuard tend to be non-specific and can have various causes. Some of the most likely causes are listed here.
Possible cause: Mixing obfuscated and non-obfuscated versions of the same JAR(s).
Solution: Verify that the classpath only contains the obfuscated JARs.
Possible cause: ProGuard optimization is enabled.
Solution: ProGuard optimization occasionally causes problems. It’s recommended to disable it with
jce.jarwere not specified as
Solution: Make sure that both