LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 03-21-2007, 04:35 PM   #1
zahadumy
Member
 
Registered: May 2005
Location: Cluj, Romania
Distribution: Fedora Core 6
Posts: 226

Rep: Reputation: 31
g++ makefile question


Hello.

I have this makefile for g++ which compiles to an exe:
Code:
HelloWorld : HelloWorld.o
	g++ -o HelloWorld HelloWorld.o
HelloWorld.o : HelloWorld.cpp
	g++ -c HelloWorld.cpp
all :
	${MAKE} HelloWorld
clean :
	-del HelloWorld.o
How would I change it in order to compile the source code into an dll? I have read the manual page and searched after "dll", but nothing useful came up... Thank you.
 
Old 03-21-2007, 05:08 PM   #2
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
Which OS you want that library for?
 
Old 03-21-2007, 05:11 PM   #3
zahadumy
Member
 
Registered: May 2005
Location: Cluj, Romania
Distribution: Fedora Core 6
Posts: 226

Original Poster
Rep: Reputation: 31
Quote:
Originally Posted by Mara
Which OS you want that library for?
For now, Windows XP, but I have to do the same thing for linux soon...
 
Old 03-25-2007, 08:42 AM   #4
Mara
Moderator
 
Registered: Feb 2002
Location: Grenoble
Distribution: Debian
Posts: 9,696

Rep: Reputation: 232Reputation: 232Reputation: 232
So look here: http://www.mingw.org/MinGWiki/index....11154a632520eb

But note that building a library for Linux is not very different (you still use --shared), but the code you need to have is different. No dll-related stuff. And a different way to use the library in your program.
 
Old 03-25-2007, 05:18 PM   #5
zahadumy
Member
 
Registered: May 2005
Location: Cluj, Romania
Distribution: Fedora Core 6
Posts: 226

Original Poster
Rep: Reputation: 31
Thank you.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Makefile question ar1 Programming 3 01-26-2006 08:06 AM
Makefile.in question lucky6969b Programming 4 12-08-2005 04:32 AM
makefile question ashwin.tanugula Programming 2 10-26-2005 04:08 PM
Question about makefile taureanyang Programming 1 03-26-2005 12:57 AM
makefile question blackzone Programming 2 12-20-2004 08:03 AM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 11:00 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration