ETDA / PDFSigningAndTimestamp

Simple example project for PDF signing and timstamping
18 stars 16 forks source link

Compiling error #16

Closed chayakornjj closed 3 years ago

chayakornjj commented 3 years ago

Hi, I'm not expert on Java but i need to use this snippet to build as jar

[ERROR] Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.7.0:compile (default-compile) on project PDFSigningAndTimestamp: Compilation failure: Compilation failure:
[ERROR] /Users/ooook/Documents/Workspace/learn-poc/PDFSigningAndTimestamp/src/main/DssHelper.java:[26,43] package sun.security.provider.certpath.ldap does not exist
[ERROR] /Users/ooook/Documents/Workspace/learn-poc/PDFSigningAndTimestamp/src/main/SignAndTimeStamp.java:[205,72] incompatible types: java.io.ByteArrayInputStream cannot be converted to sun.security.pkcs11.Config
[ERROR] /Users/ooook/Documents/Workspace/learn-poc/PDFSigningAndTimestamp/src/main/DssHelper.java:[158,13] cannot find symbol
[ERROR]   symbol:   class LDAPCertStoreHelper
[ERROR]   location: class main.DssHelper
[ERROR] /Users/ooook/Documents/Workspace/learn-poc/PDFSigningAndTimestamp/src/main/DssHelper.java:[158,41] cannot find symbol
[ERROR]   symbol:   class LDAPCertStoreHelper
[ERROR]   location: class main.DssHelper
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoFailureException

I got this error after i'm try to install mvn install or mvn package

any recommendation on this?

nathamETDA commented 3 years ago
  1. Please make sure which java version that you use, this code use JDK8.
  2. Add -XDignore.symbol.file option to javac to unhide internal packages. You can find more details here. https://stackoverflow.com/questions/40448203/intellij-says-the-package-does-not-exist-but-i-can-access-the-package