Watch, Follow, &
Connect with Us

Please visit our new home
community.embarcadero.com.


Welcome, Guest
Guest Settings
Help

Thread: Compiling Midas into a 64 Bit Windows Application



Permlink Replies: 4 - Last Post: Nov 3, 2017 11:27 AM Last Post By: Rea Berryman
Rea Berryman

Posts: 10
Registered: 8/12/09
Compiling Midas into a 64 Bit Windows Application
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 3, 2017 3:13 AM
RAD Studio 10.2
C++Builder
Windows 10

Where is midas.a for compiling a 64bit Windows application?

The following works for 32bit Datasnap:

//Contributed by xiao_chong:
//Add the library path for midas.lib
#include <Datasnap.DSIntf.hpp>
#include <Datasnap.Midas.hpp>
#pragma link "midas.lib"
extern "C" HRESULT __stdcall DllGetDataSnapClassObject(REFCLSID rclsid, REFIID riid, void** ppv);
void my_startup(void) { RegisterMidasLib(DllGetDataSnapClassObject);}
#pragma startup my_startup

Thanks.
Rea
Oliver Weinheimer

Posts: 73
Registered: 8/20/04
Re: Compiling Midas into a 64 Bit Windows Application
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 3, 2017 4:26 AM   in response to: Rea Berryman in response to: Rea Berryman
Hi - i did not find a static midas lib either.
I compiled it by my own.

-> Create a new static lib
-> Add all cpp files in C:\Program Files (x86)\Embarcadero\Studio\19.0\source\data\dsnap\midas
-> Compile lib (Maybe some project options have to be changed).

Worked for me, maybe there is another way.
Rea Berryman

Posts: 10
Registered: 8/12/09
Re: Compiling Midas into a 64 Bit Windows Application
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 3, 2017 4:48 AM   in response to: Oliver Weinheimer in response to: Oliver Weinheimer
Oliver Weinheimer wrote:
Hi - i did not find a static midas lib either.
I compiled it by my own.

-> Create a new static lib
-> Add all cpp files in C:\Program Files (x86)\Embarcadero\Studio\19.0\source\data\dsnap\midas
-> Compile lib (Maybe some project options have to be changed).

Worked for me, maybe there is another way.

Thanks Oliver. I'll give this a try. Hopefully Embarcadero can supply a file or something.

I really appreciate the help!

Rea
Jeff Overcash (...

Posts: 1,458
Registered: 9/23/99
Re: Compiling Midas into a 64 Bit Windows Application
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 3, 2017 9:19 AM   in response to: Rea Berryman in response to: Rea Berryman
Rea Berryman wrote:
RAD Studio 10.2
C++Builder
Windows 10

Where is midas.a for compiling a 64bit Windows application?

The following works for 32bit Datasnap:

//Contributed by xiao_chong:
//Add the library path for midas.lib
#include <Datasnap.DSIntf.hpp>
#include <Datasnap.Midas.hpp>
#pragma link "midas.lib"
extern "C" HRESULT __stdcall DllGetDataSnapClassObject(REFCLSID rclsid, REFIID riid, void** ppv);
void my_startup(void) { RegisterMidasLib(DllGetDataSnapClassObject);}
#pragma startup my_startup

Thanks.
Rea

Look at linking in libmidas.a

For Delphi this is midaslib.dcu, not sure why they reversed the name.

--
Jeff Overcash (TeamB)
(Please do not email me directly unless asked. Thank You)
Learning is finding out what you already know. Doing is demonstrating that you
know it. Teaching is reminding others that they know it as well as you. We are
all leaners, doers, teachers. (R Bach)
Rea Berryman

Posts: 10
Registered: 8/12/09
Re: Compiling Midas into a 64 Bit Windows Application
Click to report abuse...   Click to reply to this thread Reply
  Posted: Nov 3, 2017 11:27 AM   in response to: Jeff Overcash (... in response to: Jeff Overcash (...
Look at linking in libmidas.a

For Delphi this is midaslib.dcu, not sure why they reversed the name.

--
Jeff Overcash (TeamB)

Thanks Jeff.

I found libmidas.a for Android, IOS, and Linux but not for Windows.

I wonder if it is just my installation of RAD Studio or if this file was left out inadvertently.

Legend
Helpful Answer (5 pts)
Correct Answer (10 pts)

Server Response from: ETNAJIVE02