Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
HomeAnnouncementsFree MagazinesWhite PapersSubmit Content
Discussion GroupsASP.NETWindows FormsLanguages.NET FrameworkVisual Studio.NET
Articles.NET FrameworkASP.NETToolsWindows Forms
.NET DirectoryOpen Source ProjectsUser GroupsWeb Resources
Related Topics
Visual Basic 6SQL ServerMS AccessOther DB ProductsMS Server ProductsMore Topics ...

.NET Forum / Languages / Managed C++ / December 2006

Tip: Looking for answers? Try searching our database.

getopt.h in VS2005 c++

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
auditory - 30 Nov 2006 05:45 GMT
I have sources written on linux quite long ago.
They are compiled good on current linux machine.
but not in VS2005.

The cause of  problem is #include<getopt.h>.
Is there any correspoinding files which can be used instead of getopt.h??

I tried xgetopt.h from codeproject
http://www.codeproject.com/cpp/xgetopt.asp

but this is not compatible with getopt.h at all, and
gives lots of error in compile time.
( eg. not defined structure option, macro requied_options and so on.)

Is there any way to re-use these sources with the least modifications?
Doug Harrison [MVP] - 30 Nov 2006 05:54 GMT
>I have sources written on linux quite long ago.
>They are compiled good on current linux machine.
[quoted text clipped - 11 lines]
>
>Is there any way to re-use these sources with the least modifications?

Download a small GNU project that uses getopt and port the getopt part. It
should be very easy, though you may have to GPL your code. Sorry, but I
don't know of any free replacement for the GNU getopt.

Signature

Doug Harrison
Visual C++ MVP

Ben Voigt - 04 Dec 2006 15:37 GMT
>>I have sources written on linux quite long ago.
>>They are compiled good on current linux machine.
[quoted text clipped - 15 lines]
> should be very easy, though you may have to GPL your code. Sorry, but I
> don't know of any free replacement for the GNU getopt.

BSD has a getopt as well that doesn't suffer from the same licensing
restrictions (you should acknowledge use of the code but no infectious
license).

Free Magazines

Get these publications absolutely FREE for up to 12 months. There are no hidden fees and no obligation. Simply choose a title, complete the application form and submit it. Read more ...

Oracle MagazineNetwork ComputingComputer WorldBio-IT WorldeWeekInformation WeekInfosecurity
 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2008 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.