Note that there are some explanatory texts on larger screens.

plurals
  1. POMicrosoft 2010 visual c , installing FLTK
    primarykey
    data
    text
    <p>FLTK problems with MSV2010C++</p> <p>I'm following "Programming - Principles and Practice Using C++".</p> <p>Having a bad time trying to get FLTK running correctly. I worked for me, once, then never again. I have detailed the steps taken below, and would really appreciate it if anyone can notice anything strange.</p> <p>My main concerns are the following: 1) The steps in the Linker > Input > Additional dependencies are a little confusing 2) I have built both solutions for 1.1.9 and 1.3.0. Could these conflict? 3) My understanding of the process is basic to say the least.</p> <p>What does building actually achieve? What objects will it create? How can I check these have been made correctly?</p> <p>System Windows 7(64 bit) (Microsoft 2010 Visual C++)</p> <p>Steps tried for fltt 1.1.9</p> <p>1 Download fltk-1.1.9-source</p> <p>2 The vlC2005 solution gives me the following results:</p> <pre><code>========== Build: 66 succeeded, 3 failed, 0 up-to-date, 1 skipped ========== </code></pre> <p>3 Copied the lib files from the source to x:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib</p> <p>4 Copied the FL FOLDER into (so the folder is added / replaced) x:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\</p> <p>5 If I try to run the solution, it fails - </p> <pre><code>========== Build: 6 succeeded, 3 failed, 0 up-to-date, 0 skipped ========== </code></pre> <p>6 Create a new project named graphics6, as a win32 project</p> <p>7 Application settings - Windows application &amp; empty project</p> <p>8 In the source files, created graphics6.cpp, added the following code </p> <pre><code> #include &lt;FL/Fl.h&gt; #include &lt;FL/Fl_Box.h&gt; #include &lt;FL/Fl_Window.h&gt; int main() { Fl_Window window(200,200,"Window Title"); Fl_Box box(0,0,200,200,"Hey"); window.show(); return Fl::run(); } </code></pre> <p>9 When I run it, I get the following</p> <pre><code> 1&gt;MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup </code></pre> <p>10 Alter the project settings - Linker > Input > Additional dependencies:</p> <pre><code> "kernel32.lib;user32.lib;gdi32.lib;winspool.lib;comdlg32.lib;advapi32.lib; shell32.lib;ole32.lib;oleaut32.lib;uuid.lib;odbc32.lib;odbccp32.lib;%(fltkd.lib wsock32.lib comctl32.lib fltkjpegd.lib fltkimagesd.lib)" </code></pre> <p>11 When I run, I get this -</p> <pre><code> 1&gt;MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup </code></pre> <p>Conclusion 1.1.9 cannot be built under MS2010VC++</p> <p>Let's try 1.3 instead -------</p> <p>1 Download 1.3 and run the solution \fltk-1.3.0-source\fltk-1.3.0\ide\VisualC2010\fltk.sln</p> <p>2 Built it (I've done this a few times, so it gives the following result :</p> <pre><code>========== Build: 0 succeeded, 0 failed, 79 up-to-date, 0 skipped ========== </code></pre> <p>3 If I run it, I get the graphics on the screen. So far so good!</p> <p>4 Copied the lib files from the source to x:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\lib</p> <p>5 Copied the FL FOLDER into (so the folder is added / replaced) x:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\include\</p> <p>6 Steps 6 - 8 are the same as above, so just loaded the previous project.</p> <p>7 When I run</p> <pre><code> 1&gt;MSVCRTD.lib(crtexew.obj) : error LNK2019: unresolved external symbol _WinMain@16 referenced in function ___tmainCRTStartup 1&gt;C:my information \visual studio 2010\Projects\graphics6\Debug\graphics6.exe : fatal error LNK1120: 1 unresolved externals ========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ========== </code></pre> <p>8 added Ignore Default Libraries> libcd.lib </p> <p>9 Ran it again with the same results</p> <p>Sorry about the length of this, but I feel the only way to clarify the problem is to include all the details.</p> <p>As far as I can see, I'm following the instructions as closely as I can. The major problem being that I cant run 1.1.9.</p> <p>I've searched for solutions to this problem on a number of sites, but have yet to find a detailed step by step write up of the process. </p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload