looking for tutorial on creating DLL

F

Fabrice

Hi !

I'm looking for a tutorial on how to create a DLL in C (not C++). I
don't know whether i can use C for this purpose, but i didn't find any
post telling me that i cannot use C. So, if it is possible to use C,
please tell me how can i start learning to do a DLL file. Thanks !

Regards,
Fabrice
 
T

Tom St Denis

osmium said:
You can write a DLL in C if you have a Microsoft friendly compiler. But
DLLs are an abomination invented by Microsoft and so are not discussed in
this newsgroup. Try looking at the documentation that came with your
compiler. You might also try a google search with such terms as: dll c
tutorial <your compiler's name>

You can make DLLs with Cygwin [hint it has a switch "-mdll" for a reason].

That being said you shouldn't discuss DLL's in clc not because they are an
abomination invented by microsoft [as you so 13371y put it] but that they
have NOTHING TODO WITH THE C LANGUAGE!

Tom
 
O

osmium

Fabrice said:
I'm looking for a tutorial on how to create a DLL in C (not C++). I
don't know whether i can use C for this purpose, but i didn't find any
post telling me that i cannot use C. So, if it is possible to use C,
please tell me how can i start learning to do a DLL file. Thanks !

You can write a DLL in C if you have a Microsoft friendly compiler. But
DLLs are an abomination invented by Microsoft and so are not discussed in
this newsgroup. Try looking at the documentation that came with your
compiler. You might also try a google search with such terms as: dll c
tutorial <your compiler's name>
 
M

Mark McIntyre

On 17 Jan 2004 01:48:43 -0800, in comp.lang.c ,
Hi !

I'm looking for a tutorial on how to create a DLL in C (not C++). I
don't know whether i can use C for this purpose,

you certainly can, indeed its trivial. Except when required to provide
com interfaces, I prefer C for dlls.
However its offtopic in CLC. I'm sure the good folk in comwp can help
you.
 
M

Mark McIntyre

You can write a DLL in C if you have a Microsoft friendly compiler. But
DLLs are an abomination invented by Microsoft

well strictly neither of those last statements is true, but the next
one (without the "so") is
 
R

Richard Heathfield

osmium said:
You can write a DLL in C if you have a Microsoft friendly compiler.

Indeed; but then, you can write a DLL in C even if you have nothing but
pencil and paper.

Furthermore, DLLs were around in the mainframe world when Windows was just a
gleam in Tim Patterson's eye, so I don't know why Microsoft is even
relevant to this discussion.
But
DLLs are an abomination invented by Microsoft

Not so. Dynamic linking has been around for a *long* time, and - in a
/controlled/ environment - it is a very sensible solution to what used to
and still can be a very real problem.
and so are not discussed in this newsgroup.

Yes and no. What if a dynamic linked library is written entirely in C? I
think such code would be topical here. For example, the following code is
not wonderful, but surely it is at least topical:

/* add.h */
int add(int, int);

/* add.c */
int add(int a, int b)
{
return a + b;
}

If I then tell you that this code constitutes a dynamic linked library, does
it make the code suddenly off-topic?

I agree that instructions on how to build the DLL itself are off-topic,
since they are not standardised.
 
O

osmium

Richard said:
Indeed; but then, you can write a DLL in C even if you have nothing but
pencil and paper.

Furthermore, DLLs were around in the mainframe world when Windows was just a
gleam in Tim Patterson's eye, so I don't know why Microsoft is even
relevant to this discussion.

Why is DLL capitalized six times above? Because it is a proper name, that's
why. It is *the* name for Microsoft's version of a particular kind of
library. Invention was the wrong word, product would have been a better
choice. The chances of a randomly designed interface for a dynamically
linked library matching the interface specified by Microsoft are remarkably
close to zero. Thus my comment on "Microsoft friendly". If one means a
dynamic library, one says "dynamic library". One doesn't say DLL. They are
certainly *not* synonymous. If one says Macintosh apple, he means Macintosh
apple. If he says apple he means apple. Do you grasp the concept of how
different apples are different? How difficult can this be to understand?
This is not complicated stuff.
 
M

Mark McIntyre

Why is DLL capitalized six times above? Because it is a proper name, that's
why. It is *the* name for Microsoft's version of a particular kind of
library.

The abbreviation was being used before MS came along, AFAIR.
And its capitalised because most acronyms are capitalised. AFAIR isnt
written afair or Afair is it?

close to zero. Thus my comment on "Microsoft friendly". If one means a
dynamic library, one says "dynamic library". One doesn't say DLL.

Agree many people assume that DLLs exist only in a microsoftian
world.
 
P

Peter Nilsson

Mark McIntyre said:
The abbreviation was being used before MS came along, AFAIR.
And its capitalised because most acronyms are capitalised. AFAIR isnt
written afair or Afair is it?


Agree many people assume that DLLs exist only in a microsoftian
world.

Judging from my own observation, most _programmers_ are quite aware of
dynamic link libraries as a general concept. Microsoft, however, was
the first to force knowledge of their existance on humble _end users_!

[Mind you, old Apple Macs did require users to tweak some
application's memory allocation from time to time... ;-]
 
J

J Bennett

Mark McIntyre said:
The abbreviation was being used before MS came along, AFAIR.
And its capitalised because most acronyms are capitalised. AFAIR isnt
written afair or Afair is it?
Acronym and abbreviation are not one and the same thing. DLL is an
abbreviation, laser is an acronym.

I was just waiting to see it's not its and regular not frequent, oh
hang on a second, I've just spotted isnt :)
 
J

Jared Dykstra

Acronym and abbreviation are not one and the same thing. DLL is an
abbreviation, laser is an acronym.

While your first statement is correct, you're wrong about DLLs:

Acronym - a word formed from the initial letter or letters of each of
the successive parts or major parts of a compound term. (www.m-w.com)

* DLL (in this context) is an acronym that stands for Dynamic Linked
Library
* Laser is also an acronym for "Light Amplification by Stimulated
Emission of Radiation"

....I apologize for the off-topicness, but this should be corrected.

And for all those that think .dlls are a bad invention, imagine life
without them. For the Microsoftians out there, changes to DLLs have
been introduced with .NET to eliminate the versioning conflicts which
currently do cause lots of problems.
 
J

Jason Bennett

Jared Dykstra said:
(e-mail address removed) (J Bennett) wrote in message

While your first statement is correct, you're wrong about DLLs:

Acronym - a word formed from the initial letter or letters of each of
the successive parts or major parts of a compound term. (www.m-w.com)

* DLL (in this context) is an acronym that stands for Dynamic Linked
Library
* Laser is also an acronym for "Light Amplification by Stimulated
Emission of Radiation"

...I apologize for the off-topicness, but this should be corrected.
Apology accepted, but DLL is not a word ... DLL is pronounced D-L-L
 
R

Richard Heathfield

Jared Dykstra wrote:

While your first statement is correct, you're wrong about DLLs:

Acronym - a word formed from the initial letter or letters of each of
the successive parts or major parts of a compound term. (www.m-w.com)

dll isn't a word.
 
D

Default User

Jared said:
While your first statement is correct, you're wrong about DLLs:

Acronym - a word formed from the initial letter or letters of each of
the successive parts or major parts of a compound term. (www.m-w.com)

You left out an important part of the m-w.com definition:

: a word (as NATO, radar, or snafu) formed from the initial letter or
letters of each of the successive parts or major parts of a compound
term

The parenthetical portion you ommitted, the examples, shows why you are
incorrect in your assertion.
...I apologize for the off-topicness, but this should be corrected.

Not so, because it wasn't wrong. You are.




Brian Rodenborn
 
R

Richard Heathfield

gabriel said:
No, it's an acronym....

Look At Your Own Definition. You agree that it is not a word.

All acronyms are words.
The letter-group "dll" is not a word.
Therefore, "dll" is not an acronym.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

Forum statistics

Threads
474,135
Messages
2,570,783
Members
47,341
Latest member
hanifree

Latest Threads

Top