ide/VisualC2008/fltk.sln ide/VisualC2010/fltk.sln
To be honest, I am new to programming so this is the first thing that I have tried to build.- I am using Visual Studio 2022 (specifically version 17.2.6)- I downloaded FLTK 1.3.8 from here: https://www.fltk.org/software.php- I am trying to build the ide VisualC2010 project. ie:ide/VisualC2010/fltk.sln
My procedure for building follows the steps from the "README.MSWindows" file (specifically the "HOW TO BUILD FLTK USING VISUAL STUDIO 2010 OR LATER" section). I unzip the downloaded fltk file using 7-Zip and store it in the equivalent to my dev folder. Then I open the file .../fltk-1.3.xxxx/ide/VisualC2010/fltk.sln in Visual Studio. I make sure "demo" project is set as Startup Project and proceed to Build Solution in the Build tab.
On Wednesday, 9 November 2022 at 17:44:43 UTC Ben Stucki wrote:
To be honest, I am new to programming so this is the first thing that I have tried to build.- I am using Visual Studio 2022 (specifically version 17.2.6)
- I downloaded FLTK 1.3.8 from here: https://www.fltk.org/software.php- I am trying to build the ide VisualC2010 project. ie:
ide/VisualC2010/fltk.sln
Sounds like it should work... I do not have VS 2022, but the last few VS iterations I have used have done a fair job of reading the old .sln file and so forth...
That said, I'm not a fan of telling other to "reinstall" their software, but: are you sure you VS 2022 installation is correct and up-to-date? You can supposedly check if there's a new patch available inside the VS application.
As I said, I don't recommend reinstalling software (I hate to do this, it shouldn't be necessary), but maybe reinstalling VS 2022 or trying VS 2019 could help.
However, before you do this, can you try to build a standard "hello world" program with your existing VS 2022?
On 10 November 2022, at 16:36, Albrecht Schlosser <Albrech...@online.de> wrote:
>
>
>On 11/10/22 09:32 Ian MacArthur wrote:
>
>On Wednesday, 9 November 2022 at 17:44:43 UTC Ben Stucki wrote:
>
>To be honest, I am new to programming so this is the first thing that I have tried to build.
>
>- I am using Visual Studio 2022 (specifically version 17.2.6)
>
>- I downloaded FLTK 1.3.8 from here: https://www.fltk.org/software.php
>
>- I am trying to build the ide VisualC2010 project. ie:
>
> ide/VisualC2010/fltk.sln
>
>Sounds like it should work... I do not have VS 2022, but the last few VS iterations I have used have done a fair job of reading the old .sln file and so forth...
>
>I can only agree with Ian and add that I also don't have VS 2022 installed (I'm using VS 2019 on Windows 10 for testing FLTK). I don't remember when I tried building FLTK 1.3 the last time (it's probably long ago).
I've installed VS2022 and updated my application to it. The only change was the updating the MSVC library which went through without a problem. I didn't recompile FLTK though. I installed it on the recommendation of another library supplier (hamlib).
That said, I would rather go back to VS2019. My 8GB laptop isn't big enough now. I am actively looking for a less bloated development environment. My Linux experience is limited to Verilog rather than C++.
Phil.
>That said, I'm not a fan of telling other to "reinstall" their software, but: are you sure you VS 2022 installation is correct and up-to-date? You can supposedly check if there's a new patch available inside the VS application.
>As I said, I don't recommend reinstalling software (I hate to do this, it shouldn't be necessary), but maybe reinstalling VS 2022 or trying VS 2019 could help.
>However, before you do this, can you try to build a standard "hello world" program with your existing VS 2022?
>
>--
>You received this message because you are subscribed to the Google Groups "fltk.general" group.
>To unsubscribe from this group and stop receiving emails from it, send an email to fltkgeneral...@googlegroups.com.
>To view this discussion on the web visit https://groups.google.com/d/msgid/fltkgeneral/10868bc3-69d2-9372-2d72-624b89d7008d%40online.de.
I've installed VS2022 and updated my application to it. The only change was the updating the MSVC library which went through without a problem. I didn't recompile FLTK though. I installed it on the recommendation of another library supplier (hamlib).
That said, I would rather go back to VS2019. My 8GB laptop isn't big enough now. I am actively looking for a less bloated development environment. My Linux experience is limited to Verilog rather than C++.
I just updated VS to the newest version available, and the build still fails. I tried building a "Hello, World" project and I believe it worked as the output window read:"Build started...
========== Build: 0 succeeded, 0 failed, 1 up-to-date, 0 skipped ==========
========== Elapsed 00:00.092 =========="
I am pretty sure I have VS 2022 installed correctly as I have been using it for the past 3 or so months just fine. I think I will try installing VS 2019 and see if it works then.Thanks for the recommendations though.
Can confirm an error about winnt.h while building the
resizebox test program.
I just downloaded/installed VS 2022, built fltk 1.3.8 from the
website tar file
in "Release" mode and I get:
:
:
19>C:\Program Files (x86)\Windows
Kits\10\Include\10.0.22000.0\um\winnt.h(6497,11): error C2059: syntax error: 'constant'
19>C:\Program Files (x86)\Windows
Kits\10\Include\10.0.22000.0\um\winnt.h(6497,16): error C2238:
unexpected token(s) preceding ';'
19>Done building project "resizebox.vcxproj" --
FAILED.
:
:
========== Build: 78 succeeded, 1 failed, 0 up-to-date, 0
skipped ==========
========== Elapsed 04:48.937 ==========
We'll look into a solution, but I wouldn't worry too much
about the error
since it's just one of the FLTK test program examples failing
to build;
the library itself has already built OK and should be usable.
Devs, not sure what the problem is; seems to be something in
the VS files
and not FLTK. Not sure why resizebox is the only one
triggering this, unless
maybe we have a macro causing trouble.
Looking at that section of the winnt.h file, line 6497:
Seems to not like the 'B' in the line, if I'm counting the characters right.6487 //
6488
6489 typedef union _ARM64_NT_NEON128 {
6490 struct {
6491 ULONGLONG Low;
6492 LONGLONG High;
6493 } DUMMYSTRUCTNAME;
6494 double D[2];
6495 float S[4];
6496 WORD H[8];
6497 BYTE B[16];
6498 } ARM64_NT_NEON128, *PARM64_NT_NEON128;
6499
6500 #if defined(_ARM64_)
Looking at that section of the winnt.h file, line 6497:
Seems to not like the 'B' in the line, if I'm counting the characters right.6487 //
6488
6489 typedef union _ARM64_NT_NEON128 {
6490 struct {
6491 ULONGLONG Low;
6492 LONGLONG High;
6493 } DUMMYSTRUCTNAME;
6494 double D[2];
6495 float S[4];
6496 WORD H[8];
6497 BYTE B[16];
6498 } ARM64_NT_NEON128, *PARM64_NT_NEON128;
6499
6500 #if defined(_ARM64_)
CHANGES IN FLTK 1.3.9 RELEASED: Nov ?? 2022 FLTK 1.3.9 is a maintenance release with some fixes and enhancements. Details: Albrecht Schlosser: Backport X11 INCR protocol fixes from 1.4.0 (issue #451) X11: Suppress compiler warnings when using gcc or clang Fix crash if a program exits before it opens a window (STR 3484). Fix compilation error with current Visual Studio 2022 ManoloFLTK: macOS platform: fix for issue #325 Disabling IM disables Greek and Cyrillic layouts Fix fullscreen window level corner cases on macOS - cont'd Fix for issue #373 apparent with macOS platform and SDK ≤ 10.13 Fi xfor issue #452: Fl::get_font_name failure on OS-X. Fix for issue #454 : crash in Fl::get_font_name(). Issue #469: Fl_Sys_Menu_Bar menu item shortcuts using Escape or Tab do not work on Mac YX: Fix IME problem (issue #270)(End of new items in CHANGES).
Yes, there is a bug in resize box that I fixed in 1.4.0 a few days ago. The first lines of the source file contain #define B 0 , and only after those unhappy defines, the header files are included. So anything in the header that has a keyword "B" will have it replaced with the number "0".
Simply move the three #define lines after the include statement, and everything is peachy.
On 11/24/22 23:05, Stephen Zuniga wrote:
Hi everyone, thanks for your discussion. I came across Ben's question because I am having the same issue with Visual Studio 2022 and FLTK 1.3.8. I am attaching the same 2 errors at the same line discussed above.
#define W1 (big ? 60 : 40)
#define B 0
#define W3 (5*W1+6*B)
... #include <FL/Fl.H> #include <FL/Fl_Double_Window.H> #include <FL/Fl_Box.H> #include <FL/Fl_Radio_Button.H> #include <FL/fl_draw.H> #include <FL/fl_message.H>
#define W1 (big ? 60 : 40) #define B 0 #define W3 (5*W1+6*B)
Fl_Double_Window *window; Fl_Box *box; ...
That will solve that build error.
Thank you, Greg!!
I really appreciate your quick reply and helpful response.
I will give it a try and I am sure it will work fine. And it is very reassuring to read that it won't affect the build or the other test demos.
Thanks again for your help!