-
-
Notifications
You must be signed in to change notification settings - Fork 53
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Incorrect javac options #14
Conversation
Ant appends "-g:none" as default. "-g:lines,vars,source" is a mandatory field for javac since debug information in the class file is used by the convertor
Could you give some pointers to why compiling with debug information is mandatory ? |
The debug info inside classes is used by the convertor(com.sun.javacard.converter.Converter) to generate cap files. Without that the convertor gives out compile error stating "unsupported int type of intermediate value, must cast intermediate value to type short or byte". I will try to provide sample code demonstrating this. |
I should make it more clear that by default converter code in ant-javacard does not enable integer support. I found another interesting reference, I did not know this before: https://docs.oracle.com/javacard/3.0.5/devnotes/index.html#BAJBJAHF |
In the light of the known issue with 3.0.5u1 kit and the missing support for int32, I will rephrase the goal of this ticket in a new ticket: add support for int types. Int support is not that popular in commonly, freely available cards. Thus I will not enable this by default. If you can provide something I can verify or test, I might reconsider. For now, you can manually enable debug mode if needed. |
The problem is not with the int flag. I have manually disabled it since my card does not support it. The debug option is mandatory. Please compile the code using JCDE it also uses "-g:lines,vars,source". |
You are right, the user guide suggests to compile always with |
Ant appends "-g:none" by default. "-g:lines,vars,source" is a mandatory field for javac since debug information in the class file is used by the convertor