Code Generator: IDL to .h and .cxx. How to NOT generate plugin and support files via command line

4 posts / 0 new
Last post
Offline
Last seen: 3 months 2 weeks ago
Joined: 04/22/2019
Posts: 6
Code Generator: IDL to .h and .cxx. How to NOT generate plugin and support files via command line

I'm simply trying to compile some ild files. What arguments can I include to prevent the plugin and support files from being generated?

My command line command is something like:

pathToRTIDDSGEN   -inputIdl pathToInput  -d pathToOutputCompiledFiles  -replace -language C++ -namespace -optimization 2 -verbosity 3

 

Organization:
Offline
Last seen: 5 months 3 weeks ago
Joined: 12/05/2019
Posts: 16

Hello,

As far as I'm aware, what you intend to do is not possible. RTI Code Generator has three output kinds:

  • typefiles: These are the Language Bindings of the DataType definition, including TypePlugin and TypeSupport if applicable.

  • examplefiles: These are Publisher and Subscriber examples using the above Language Bindings.
  • makefiles: These are the Project definitions and/or Build files for the examples.

By default, if no -example, -create or -update flag is used, RTI Code Generator will generate the typefiles.

What do you intend to do? If what you want to achieve is using RTI Connext DDS to publish samples, you will require the whole typefiles.

Regards,
Alejandro

Gerardo Pardo's picture
Offline
Last seen: 1 week 2 days ago
Joined: 06/02/2010
Posts: 602

Hi,

I think it is possible to not generate the type support and plugin files.

An easy way to see the various command options you can use wirth rtiddsgen is to use the  RTI Launcher UI. From RTI Launcher if you click on the "Code Generatot" you get a window (see the attached image).

You can see 3 pulldown menus that controls the genared code, separated into 3 categories:

  • Example files. This controls the geberation of the exaple Publisher and Subscriber
  • Type files. This controls the genration of the TypeSupport and TypePlugin files
  • Makefiles. Generation of a makefile

For each of these categoreis you can select "create", "update", or "<disable>".

  • create means the corresponding file(s) are created if they do not exist. But it they do exist they are not modified. Yiou typically use this option with the Example files and the makefile. That way they are created the first time for you but not changed afterwards so that if you make any chabges to them (as it typical for example files) those changes aere not lost when you run rtiddsgen again.
  • update means the corresponding file(s) are always wrtitten. So they are created if they do not exist and updated if they already exist. This is what you typically want to do with the "typefiles" since they are tied to the IDL and should not be edited by hand.
  • <disable> this means these files are not created or updated.

You can run rtiddsgen directly from the UI, or use it as a way to see which command-line options you need to use. You do this checking the "Conferm command" button next to the "Run" button. If you check this, then the "Run" button changes to a "Check" buttoon and when you click on it you get a popup with the command-lien options that would be passed to rtiddsgen.

For example, if you juist wanted to create the makefile and the example files but not generate or modify the plugin and support files, then you could select <disable> in the "Type files" menu, and click on the "Check button". You will see the attached popup. You can copy paste the comamnd line parametes from there so you would get somethign like:

rtiddsgen -ppDisable -language C++ -create examplefiles -create makefiles -platform x64Darwin17clang9.0.  <path_to_the_DL_file>

I tried it out and this does not generate the type pligin/support files.

Gerardo

Offline
Last seen: 3 months 2 weeks ago
Joined: 04/22/2019
Posts: 6

Thank you for your response, Gerardo. The check button pop-up is very helpful. 

v/r CG