[CONNECT C++] Module "concepts" and compilation parameters

Hi all,

I am trying to help a user in the process of MDL migration from V8i to CONNECT, and I have some doubts with some modules and objects equivalences and link parameters.

This is how they are currently working in V8i:

1 - They create a .DLL from .C++ code (creating a .DLO object)

2 - Create several .MO files from different .MC files

3 - Compile the .MO files together with the .DLO to create a .MP

4 - Finally they create a .MA file from the .MP

I have tried to identify the equivalent steps in CONNECT reviewing all the SDK CONNECT examples and the documentation, and this is what I have understood they need to do:

1 - Create .OBJ files from .CPP source

2 - Compile the resources (RSC) files into a .MI file

3 - Combine the .MI file with additional external resources to create the final .MA

Am I right?

Are the .MI files the equivalent to the V8i .MO files?

Where do we need to include the .DLO files to be linked? And the .OBJ? Together with the .MI in the .MA generation?

Thanks a lot in advance.

Eduardo Cortes

  • Build a Legacy MDL Application

    Unknown said:
    This is how they are currently working in V8i

    ...

    1 - Create .OBJ files from .CPP source

    MDL is a C language, not C++.  With V8i and earlier you create .mo object files from a .mc source file.

    Build a CONNECT Application

    Unknown said:

    3 - Combine the .MI file with additional external resources to create the final .MA

    Am I right?

    Almost: when you build an app. using the CONNECT MicroStationAPI then the implementation of the app. is written in C/C++.

    C++ source (*.cpp) files  are compiled to object (*.obj) files.  Visual Studio resources (e.g. message lists, version no. in a *.rc file) may also be compiled into a *.res binary file.  The Viz Studio linker combines those object files into the DLL executable.

    At the same time you need a .ma file.  Since the implementation is all in the C++ code, the .ma file is used for MicroStation resources.  Your customer still needs to compile his MDL resource (*.r) files into binary *.rsc files.  For example, a command table is a MicroStation resource about which Viz Studio knows nothing: you must still build the .ma app. to store command table resources and others, such as message lists and other MicroStation-specific binary data.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: Eduardo Cortes 

  • Thanks, Jon.

    Just a question I have no answer yet:
    Could somebody confirm if the .MI files (in CONNECT) are the equivalent to the V8i .MO files?

    Thanks in advance,



  • Unknown said:
    V8i .MO and .MI files?

    Both  .mo and .mi files are temporary (intermediate) files created by bmake during a build. 

    MicroStation V8i and Earlier

    If you use bmake to build an MDL application, then the MDL compiler (mcomp.exe) compiles code source (.mc) files to object (.mo) files.

    The resource compiler (rcomp.exe) compiles resource source (.r) files to intermediate binary (.mi) files.

    MicroStation CONNECT

    You can't compile code (.mc) files with bmake, so .mo files don't exist.

    You can continue to compile MDL resources, so .mi files continue to exist.  They are temporary files.

     
    Regards, Jon Summers
    LA Solutions

    Answer Verified By: Eduardo Cortes