Solved

Somehow creating a 64bit DLL with Borland C++ Builder?

Posted on 2012-04-03
4
903 Views
Last Modified: 2012-08-02
I've created a 32bit DLL in Borland C++ Builder XE2 no problem.

I was tasked to create a 64bit version as well. After researching the "hows" I came to know that Builder does not yet support 64bit compilations.

After some digging around it looked as though the only way to do this ( or any kind of 64bit compiling) was to use visual studio express command lines. Thus I tried the following commands to try to compile:

CALL "C:\Program Files\Microsoft SDKs\Windows\v7.1\Bin\SetEnv.Cmd" /x64
"C:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64\cl.exe" -IC:\projects\dll -I"C:\Program Files (x86)\Embarcadero\RAD Studio\9.0\include\windows\vcl" -I"C:\Program Files (x86)\Embarcadero\RAD Studio\9.0\include\windows\rtl" -MD -LD C:\projects\dll\dll.cpp -FeMyDLL.dll

Open in new window


Running the above gives me the following error:

C:\Program Files (x86)\Embarcadero\RAD Studio\9.0\include\windows\rtl\sysmac.h(162) : fatal error C1189: #error : "System.hpp/sysmac.h and related headers need __declspec(uuid(..)) and __uuidof support"

Open in new window


Mucking about on Google only gave me some posts on adding #define DECLSPEC_UUID(guid) which doesn't help at all.

So my question is, has anyone ever successfully compiled a borland c++ project (or an application / dll created in borland) for 64 bit (plus a step-by-step on how)? Or if anyone can help with the above error message, it would be greatly appreciated.

--
Hein.
0
Comment
Question by:ilanazbel
4 Comments
 
LVL 21

Expert Comment

by:developmentguru
ID: 37821554
I found a hint for you in the RAD Studio XE2 help.  Bring up the help and place this in the URL:

ms-help://embarcadero.rs_xe2/rad/The_declspec_Keyword_Extension.html

Towards the bottom it gives an explanation of the declspec as it applies to using a GUID with a COM style object being defined in a DLL.  

If you need to define one, just hit [Ctrl][Shift][G] and it will create the statement for you.  Placing this near the top of your project file should give you the ID it is looking for.

I post this as an attempt to help you out.  I use Delphi XE2 as the syntax is FAR more readable than the C++ is.  Having stated that, it has been many years since I compiled anything in C++, so I cannot give you a step by step.
0
 

Accepted Solution

by:
ilanazbel earned 0 total points
ID: 37841273
There is no answer to this question. After being in touch with borland themselves it seems as though 64 bit support *might* only be supported in c++ from XE3.
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 38249579
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

IT, Stop Being Called Into Every Meeting

Highfive is so simple that setting up every meeting room takes just minutes and every employee will be able to start or join a call from any room with ease. Never be called into a meeting just to get it started again. This is how video conferencing should work!

Join & Write a Comment

Entering a date in Microsoft Access can be tricky. A typo can cause month and day to be shuffled, entering the day only causes an error, as does entering, say, day 31 in June. This article shows how an inputmask supported by code can help the user a…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.
In this fourth video of the Xpdf series, we discuss and demonstrate the PDFinfo utility, which retrieves the contents of a PDF's Info Dictionary, as well as some other information, including the page count. We show how to isolate the page count in a…

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now