Fltk1.1 with MinGw? - windows-7

I have a project that compiles in linux and I am now trying to compile it under MinGw in Windows 7. The project includes the fltk library. When I try to compile, I get the message that the FL/Fl.h file is not found -
GUIWindow.h:5:18: fatal error: FL/Fl.H: No such file or directory
compilation terminated
I downloaded the fltk 1.1 files and extracted them to my desktop. I went into the directory, configured, and compiled the files successfully. So what am I missing here to get this to install? I thought that with #include<>, if the library is installed correctly that it will find the files no matter where they are at. So what else is necessary under MinGw? Any help is appreciated.

Okay well I just cut the FL folder from the fltk folder and put it in MinGw/include. This compiles. If anyone can explain why just having #include works in linux but not in MinGw, I would be grateful.

Related

Linking my CMAKE project with libpng in Windows

I'm working on a C++ project that requires libpng. So far I've worked on Linux and everything is smooth. I installed libpng, CMAKE picks it up and everything is alright. Now move to Windows.
Here I first installed zlib (required by libpng) and libpng. When I say install, I mean I downloaded the source files, and then built them and install them using msbuild.
I noticed that by doing so, I got new folders under c:\program files (x86):
c:\program files (x86)\zlib
c:\program files (x86)\libpng
Seemed all right to me. Now when I configure my project with CMAKE zlib is picked up:
-- Found ZLIB: C:/Program Files (x86)/zlib/lib/zlib.lib (found version "1.2.13")
but there's no way CMAKE finds the PNG library:
Could NOT find PNG (missing: PNG_LIBRARY PNG_PNG_INCLUDE_DIR)
Now I tried to have a look at the FindPNG and I noticed this line:
find_path(PNG_PNG_INCLUDE_DIR png.h PATH_SUFFIXES include/libpng)
Does this mean that CMAKE expects the file png.h to be in a directory ending in include/libpng? If so, then it will never find it because in my case png.h is placed in libpng/include. But this is also the "official" installation from the source code just downloaded from http://www.libpng.org/pub/png/libpng.html.
So now I am superconfused. How things are supposed to work in Windows? Should I "create" a folder structure with the correct files for every library so that CMAKE is happy? In a way I hoped things in Windows were similar to what happens in Linux: libraries go in a standard folder, they are detected by CMAKE.. everything is ok. But apparently this is not the case. So my question in general is: how do you ship a package like this to a Windows user so that he can builds it without having to go through all this?
Thanks so much
Fabrizio
This would be the right one to use:
find_package(PNG)
You can tell CMake to look in the location where you installed it by adding the libpng base install location to CMAKE_PREFIX_PATH. Without this, CMake doesn't know where you put it.
cmake "-DCMAKE_PREFIX_PATH=C:/Program Files (x86)/libpng" ...
Note that FindPNG first looks for zlib and will fail if zlib could not be found.

missing payoffs.hpp and other .hpp from version

When building the Windows C++ version of quantlib 1.9.1, I get this error of missing payoffs.hpp. When I browse to the directories, I see payoffs.cpp, but not payoffs.hpp:
Severity Code Description Project File Line Suppression State
Error C1083 Cannot open include file: 'ql/instruments/payoffs.hpp': No such file or directory FittedBondCurve c:\users\administrator\google drive\quantlib-1.9.1\ql\cashflows\conundrumpricer.hpp 27
I also get this for #include <ql/instruments/swap.hpp> [and possibly others]. I am able to build the windows quantlib library ok. Just not the examples.
I just checked the QuantLib 1.9.1 release available from the project downloads (did you get your version from there?) and the files you're looking for are contained in the release zip and tarball. Also, it's pretty weird that you could compile the library without them, so I'd double check if they're there. If they really aren't—well, hard to know how they got displaced; anyway, you can download the release again and replace them. If that doesn't fix the problem (or if they're already there after all), it's possible that you have to fix the include path for the example you're trying to compile. Does it include the QuantLib directory?

Gstreamer on windows

I'd like to build application using Gstreamer 1.0 and GTK+-3.0 on Windows 8 (64bit).
I have sucessfully install and build GTK+-3.0, 32 bit version using Dev-C++ and Mingw 32-bit (there is no 64 bit version of GTK+). Everything works perferkt. It also installed pkg-config, I addeded it in %PATH% and it works.
I have installed gstreamer-1.0-devel-x86-1.4.4.msi and gstreamer-1.0-x86-1.4.4.msi from here
1) First problem: it installed itself into I:\gstreamer\ without asking me. I am very unhappy about it, I'd like have it on C:. But its not the biggest problem.
2) pkg-config do not know about gstreamer. I have found in I:\gstreamer\1.0\x86\lib\pkgconfig\ *.pc files, so I looked into gstreamer-1.0.pc and added to my projekt this options:
C compiler:
-I"I:/gstreamer/1.0/x86/include/gstreamer-1.0/"
Linker:
-L"I:/gstreamer/1.0/x86/lib" -lgstreamer-1.0
3) Now the program was compiled, but when I run it, it was not able to find gstreamer-1.0-0.dll. So i tried copy I:\gstreamer\1.0\x86\bin\gstreamer-1.0-0.dll into to the same directory as is my compiled file. Then it was not able to find libwinptread-1.dll. So I copied it also.
Then te program run, but it faild with some error like "cannot find entry point to windows thread ..." (I do not remember it exactly). So I copied ALL dll files from I:\gstreamer\1.0\x86\bin\ and then finally the program run.
But now it is not able to create elements:
source = gst_element_factory_make ("videotestsrc", "source");
//source is null
So, my question is, how to install gstreamer, that my program will find all dll files and will be able to create elements?
installing -- choose "custom install", there you can change the installation path.
for vs you can use *.props (gstreamer\1.0\x86\share\vs\2010\libs)
you need set Environment variable - GST_PLUGIN_SYSTEM_PATH_1_0 to plug-ins. For more details see http://gstreamer.freedesktop.org/data/doc/gstreamer/head/gstreamer/html/gst-running.html

GLEW and GLFW on Mac OS X (standalone)

I built a project on XCode using glew and glfw. The CMake file was given to me by a tutorial, so I don't actually know how to make one of the cpp files build by itself. When I pasted the code into a new standalone file, I got the errors:
error: GL/glew.h: No such file or directory
error: glfw3.h: No such file or directory
I googled these errors, but most of the solutions were for Linux and did not work for my Mac. GLEW and GLFW are indeed installed on my system, since I was using them successfully in my XCode project. I just don't know how to set the correct paths when I am compiling a standalone cpp file at the command line using g++.
use -I at the command line to indicate which include paths the compiler should search

Need help compiling libqxt for Windows

I have a Qt project which uses libqxt. How do I compile it for Windows?
Edit
Ok, I compiled it, and it's installed in "C:\Qxt\", but when I try to build my project it still fails with error
..\qlocate\mainwindow.cpp:13:29: error: QxtGlobalShortcut: No such file or directory
I assume I should change the include paths of Qt Creator, but how do I do that?
there's a problem with the headers. Read the complete guide to fixing it here:
http://qt-project.org/wiki/LibQxt_in_QtCreator
just download it from
http://dev.libqxt.org/libqxt/wiki/user_guide
and run configure.bat

Resources