944,008 Members | Top Members by Rank

Ad:
  • C++ Discussion Thread
  • Unsolved
  • Views: 1232
  • C++ RSS
Oct 20th, 2009
0

Compiling linux based static library in Windows

Expand Post »
Hi all,

I have a library built in C++ targeted for linux platform. The authors suggested that with some minor changes, it can be compiled in windows as well.. This library in turn uses the mathematical library called miracl, which does support VC++ and I was also able to build it there.

My problem is how to port this linux based library to windows?

I found a open source software known as cmake for building the source files. Is it the correct tool for my problem?

Regards,

Abhi
Similar Threads
Reputation Points: 10
Solved Threads: 0
Newbie Poster
abhipro is offline Offline
21 posts
since Sep 2009
Oct 20th, 2009
-7
Re: Compiling linux based static library in Windows
If you used g++ on linux then you should probably use Code::Blocks with MinGW compiler on Windows.
Sponsor
Team Colleague
Featured Poster
Reputation Points: 5608
Solved Threads: 2282
Retired and Enjoying Life
Ancient Dragon is offline Offline
21,953 posts
since Aug 2005
Oct 20th, 2009
0
Re: Compiling linux based static library in Windows
Hey,
Thanks. I will now try code::blocks with minGW.

Previously, I tried to port the linux based C++ code to VS 2005 using cmake utility but it didn't work.


Regards,

Abhijit
Reputation Points: 10
Solved Threads: 0
Newbie Poster
abhipro is offline Offline
21 posts
since Sep 2009
Oct 20th, 2009
0
Re: Compiling linux based static library in Windows
Hi,

I tried code::blocks with minGW compiler.

As soon as I compiled a program, it gave multiple syntax errors, as if it's not recognizing the syntax at all.
What am i doing wrong?

also, this program called headers from other library which I have already build in VS 2005 and have the library file for it. Should I be including it here in Code::Blocks?

Regards,

Abhijit
Reputation Points: 10
Solved Threads: 0
Newbie Poster
abhipro is offline Offline
21 posts
since Sep 2009
Oct 21st, 2009
0
Re: Compiling linux based static library in Windows
Hi,

I have tried many methods, like cmake and minGW, but each time I try compiling the code in Windows, errors like in braces and basic syntax are thrown.

I never worked much with unix based C++.
Is there a compiler which I can use to compile linux based C++ code successfully in Windows environment?
Reputation Points: 10
Solved Threads: 0
Newbie Poster
abhipro is offline Offline
21 posts
since Sep 2009
Oct 21st, 2009
0
Re: Compiling linux based static library in Windows
Its surprising that you are not able to compile it in windows. If you take a library compiled in *NIX, it would not run on windows but usually the code compiles fine both on windows n *nix, apart from specific system calls if you have them. braces like error are not an issue of unix or windows. Its a code issue.

edit: sorry, didnt read the whole thing, you have a library i guess. plz ignore my post in that case.
Last edited by Agni; Oct 21st, 2009 at 7:48 pm.
Featured Poster
Reputation Points: 431
Solved Threads: 116
Practically a Master Poster
Agni is offline Offline
654 posts
since Dec 2007

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in C++ Forum Timeline: Help with C++ files?
Next Thread in C++ Forum Timeline: Help: Code Sum/Factorial





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC