examples and dll's

External libraries (GTK, GSL, SDL, Allegro, OpenGL, etc) questions.
bfuller
Posts: 337
Joined: Jun 02, 2007 12:35
Location: Sydney, Australia

examples and dll's

Postby bfuller » Aug 22, 2007 11:09

When I try to run some of the examples, I get a message saying a dll is missing. I am using FBIde, and using quickrun (F5). For instance, when I try to run ft2_test, I am told freetype6.dll is missing.

When I look at the source code, I don't see any mention of freetype6 so I don't understand how/why it is being called.

Probably a simple solution, but I don't really understand dlls etc.

I have read the help file--and can see (sort of) how dlls are used in general, but still need some help please.

Some of the examples are obvious--but in others it is a bit vague what they are supposed to do---ie are they all meant to compile and run as stand alone (mini) programs--lome "hello world", or are some meant to be included in bigger projects?

Regards
Brad
wallyfblu
Posts: 69
Joined: May 24, 2006 10:58
Location: ITALY

Postby wallyfblu » Aug 22, 2007 15:47

I have found freetype6.dll in my GTK installation so for me run ok. However you could search on internet to find the missing .dll (for other examples) or look at sticky: links at top of Libraries topic. the library call is in the "freetype2/freetype.bi" file with the statement #inclib "freetype".

If you search on the forum, you will find some other dll threads that can help you.
MichaelW
Posts: 3500
Joined: May 16, 2006 22:34
Location: USA

Postby MichaelW » Aug 22, 2007 18:38

By placing the freetype6.dll from the binaries package (MD5 checksum=f135042458bc25211ecb38b2b480b34d)here, and the zlib1.dll from the compiled DLL package (MD5 checksum cc7fa97f9c19386bb701acc79d0abbca)here, in the current directory I was able to run both of the freetype examples OK.

The source does not refer to freetype6.dll or zlib1.dll directly, but the dependencies do exist, hidden in the header files, import libraries, and DLLs. For example, the source statement:

#include "freetype2/freetype.bi"

Includes the header file freetype.bi, which contains the statement:

#inclib "freetype"

Which refers to the import library libfreetype.dll.a. An import library contains the information necessary for the linker to resolve references to the functions that an EXE is “importing” from a DLL, so it can place information in the EXE that will allow Windows to load the DLL and locate the functions. For the freetype examples, the resulting EXE, in addition to importing functions from the system DLLs, is importing several functions from freetype6.dll. When Windows loads an executable, and executable here includes DLLs, it examines the imports and attempts to find and load all of the required DLLs. If Windows can find freetype6.dll it will attempt to load it. In the process of doing this Windows will determine that freetype6.dll imports functions from zlib1.dll, and attempt to load it. If Windows can find zlib1.dll then the EXE will run. If Windows cannot find any of the required DLLs, then it will display an error message.
bfuller
Posts: 337
Joined: Jun 02, 2007 12:35
Location: Sydney, Australia

Postby bfuller » Aug 23, 2007 10:39

Since I made my post, I have been reading other threads mentioning dll's. There is a lot to learn--I will do a lot more reading, and practice some more I think.

Rgds
Brad
bfuller
Posts: 337
Joined: Jun 02, 2007 12:35
Location: Sydney, Australia

Postby bfuller » Nov 28, 2007 4:16

I have tried to compile a program with #INCLUDE fmod and the compiler can't find fmod.dll

Where (what directory) am I supposed to put fmod.dll in? I have gone to the http://www.fmod.org/index.php/download website---which file should I download? Do I just run the installer??

I have looked at the WIKI--and can't seem to find any instructions on how to use dll's.

Can someone point me in the right direction please?
cha0s
Site Admin
Posts: 5317
Joined: May 27, 2005 6:42
Location: Illinois
Contact:

Postby cha0s » Nov 28, 2007 5:50

Either put it in the directory with your executable, or place it in a global path, (such as c:\Windows\system32)
bfuller
Posts: 337
Joined: Jun 02, 2007 12:35
Location: Sydney, Australia

Postby bfuller » Nov 28, 2007 6:11

OK, makes sense.

In the Libraries Sticky, there is a link to www.fmod.org
On the download page, there is a thing called "FMOD Ex Programmers API". The download is a file called "fmodapi40809win32-installer.exe"--is this what I need (I am running XP)? If I run this installer will it unpack fmod.dll for me?

I ask because as a rule I don't like running "dot exe" files unless I know what they will do to my system.

Thanks
Brad
MichaelW
Posts: 3500
Joined: May 16, 2006 22:34
Location: USA

Postby MichaelW » Nov 28, 2007 6:36

The FMOD Ex package includes the FMOD Ex DLLs, fmodex.dll, fmodexL.dll, and fmodexp.dll. On my spare system the installer created a 24.6MB FMOD Programmers API Win32 directory with 489 files and 123 folders.

FMOD.DLL is included in the version 3.75 Windows 32-bit download (a ZIP file), on the linked page under FMOD 3 Programmers API.

Return to “Libraries”

Who is online

Users browsing this forum: No registered users and 4 guests