How to run ASN.1 Compiler Command Line with ASN.1 IMPORT statement

23 views
Skip to first unread message

Koon Sang Khong

unread,
Apr 6, 2017, 10:26:24 PM4/6/17
to ASN.1 Development Tools
Hello,

I have two modules - Module A and Module B.  Module A imports some types from Module B.  When I run the command line to generate Java code, it fails to generate code for Module A as the compiler complains that it cannot resolve some types which are supposed to be imported from Module B. I noticed that the compiler actually processes the files in alphabetically ascending order of the filename.  If I restructure my modules so that Module B imports types from Module A, then, there is no issue generating source code as Module B is compiled after Module A.

Is there a way to specify the order of ASN.1 files to be compiled?

Thank you.

Regards,
Koon Sang

Zhiren Hu

unread,
Apr 7, 2017, 4:53:44 AM4/7/17
to ASN.1 Development Tools
Hi,

It is hard to tell from your description what happen.  The command line tool actually  required you to merge the ASN.1 files to a single file, I am not sure you have done that or not.

It is better if you can send the example ASN.1 files.


Regards,
Zhiren Hu  

Koon Sang Khong

unread,
Apr 7, 2017, 5:23:22 AM4/7/17
to ASN.1 Development Tools
Good pointer.  

I put all modules into a single file in the right order instead of one module one file.  It is working fine now.  Thank you very much.
Reply all
Reply to author
Forward
0 new messages