|
FLTK Installation
|
|
In the lab
FLTK is already installed and configured in the Graphics Lab.
The files are located in the directory "C:\Program Files\fltk-1.1.4\".
At home
1. Copy FLTK files
- Download FLTK 1.1.4 here. This
version is compatible with all project skeletons.
- Unzip the contents of this archive to C:\Program Files\fltk-1.1.4.
2. Configure .NET or MSVC++
- Open MSVC++ or .NET, and click Tools->Options.
- Click the "Projects/VC++ Directories" tab.
- Change the drop-down to "Include Files"
- Add the item "C:\Program Files\fltk-1.1.4"
- Change the drop-down to "Library Files"
- Add the item "C:\Program Files\fltk-1.1.4\lib"
3. Verify that your project is linking with the correct library
- In .NET, click Project->Properties...
In MSVC++, click Project->Settings...
or Alt+F7
- .NET: Click the "C++" tab.
MSVC++: Click the "C/C++" tab.
- Change the "Category" drop-down to "Code Generation".
- If the project configuration is Release, change the "Use run-time library"
drop down to "Multithreaded DLL".
- If the project configuration is Debug, change the "Use run-time library"
drop down to "Debug Multithreaded DLL".
- Click the "Link" tab.
- If the project configuration is Release, make sure that "fltk.lib",
"fltkgl.lib", "fltkimages.lib"
(and
not "fltkd.lib" ...) is present in edit box labeled "Object/Library modules".
- If the project configuration is Debug, make sure that "fltkd.lib",
"fltkgld.lib", "fltkimagesd.lib"
(and not
"fltk.lib" ...) is present in edit box labeled "Object/Library modules".
-
The addition libraries must also be present under "Object/Library modules" are
"glu32.lib",
"opengl32.lib",
"comctl32.lib", and
"wsock32.lib".
If you are using MSVC++ use these fltk libraries.
That's it!
Linux
1. Install Mesa
As the first step, you must install MesaGL. You can get the source of MesaGL from
here. To install it,
> gunzip MesaLib-3_0_tar.gz
> tar -xvf MesaLib-3_0_tar
> cd Mesa-3.0
> make linux-386
.....
Serveral minutes later, you will have libMesaGL.a and LibMesaGLU.a in Mesa-3.0/lib and
a directory called GL in Mesa-3.0/include. I usually prefer to copy all these files into
~/local/lib and ~/local/include such that I can access all the libraries without remembering
tons of paths.
2. Install Fltk
Now, we try to make fltk. You can get the source from
here.
> gunzip fltk-1.1.4-source.tar.gz
> tar -xvf fltk-1.1.4-source.tar
> ./configure
> make
Create a local directory in you home dir
Open makeinclude file and change the prefix variable to the your local
directory
> make install
> cp fltk-1.1.4/fluid/fluid ~/local/bin
> cp fltk-1.1.4/
That's it. You will have
'fluid' in ~/local/bin,
two directories, FL and Fl, in include
and libfltk.a in lib.
Now everyting is in ~/local, you need to change the value of the variable, $(LOCAL), in Makefile to
~/lcoal.
|
![CSE logo](/images/logo.png) |
Computer Science & Engineering
University of Washington
Box 352350
Seattle, WA 98195-2350
(206) 543-1695 voice, (206) 543-2969 FAX
[comments to merlin]
|