summaryrefslogtreecommitdiff
path: root/CMake
AgeCommit message (Collapse)Author
2018-12-22Removes few tabs from options.cmake. When removing tabs, also apply cmp ↵fabien
standard (two spaces) recommended indentation.
2018-12-22remove unnecessary double braces in option.cmake cairo detection codefabien
2018-12-22CMake CAIRO support minor improvements: Make the conditional code more ↵fabien
readeable by reusing the already parsed PKG_CAIRO_FOUND variable instead of testing for it again, which also simplifies the preconditions testing. Fix typo (. in endif statement comment).
2018-12-20Improve CMake's Cairo detection and issue error message...Albrecht Schlosser
... if Cairo was requested (OPTION_CAIRO or OPTION_CAIROEXT) but Cairo was not found. CMake generation is terminated with a fatal error. The user has two choices: install Cairo libs and headers or disable OPTION_CAIRO and OPTION_CAIROEXT.
2018-12-16macOS + CMake + OPTION_APPLE_X11 : restore building of GLU-based test apps.ManoloFLTK
2018-06-23Removed macro FL_PORTING, as it has been more confusing than helpful.Matthias Melcher
The original intention of FL_PORTING was to mark all places in the source code where changes are required to port FLTK to a new platform. Thanks to the driver system, this approach has become somewhat misleading, so I removed all references. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12969 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-06-19Add missing winsock dll to variables.cmake (fixes fltk-config).Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12948 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-03-16CMake/fltk-config: update fltk-config (LDFLAGS) for MacOS.Albrecht Schlosser
This is a preliminary patch to enable linking with pango on MacOS when fltk-config is used. A better solution is under development. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12759 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-25CMake + configure: improve generation of fltk-config.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12692 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-24CMake: fix fltk-config generation for MacOS.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12687 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-23CMake: Fix fltk-config for Windows and Unix/Linux.Albrecht Schlosser
This update ought to work with fltk-config [--use-images] [--use-gl] --compile <c source file> on both Windows and Unix/Linux when built with CMake. It was tested under Windows and Linux using fltk-config directly from the build tree, but it should work as well after installation. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12686 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-18CMake: fix generated fltk-config for Windows (partially).Albrecht Schlosser
This makes 'fltk-config --compile' work with simple test applications like hello.cxx etc. It may not yet work with other options though, particularly with --use-gl or --use-images, but it's an improvement. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12676 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-18CMake: fix debug macro for CMake versions before 3.4.Albrecht Schlosser
Note: string(APPEND ...) was introduced in CMake 3.4. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12675 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-09CMake: add macro fl_debug_var to debug variables.Albrecht Schlosser
Some debug messages are included, but currently disabled. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12658 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-02-09Replace "WIN32" with "_WIN32" or "Windows".Albrecht Schlosser
Replace compiler/preprocessor/platform macro "WIN32" with "_WIN32". Replace "WIN32" in text and documentation with "Windows". Replace "MSWindows" with "Windows". To do: README.Windows.txt (and maybe other documentation as well) needs updates. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12655 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-01-14CMake: test option compatibility: Pango requires Xft.Albrecht Schlosser
Abort CMake configuration/generation if Xft is disabled or not found but Pango is requested because Pango requires Xft support. A detailed warning message is issued before the CMake generation is aborted. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12631 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-01-10CMake: enable building FLTK in a subdirectory of another project.Albrecht Schlosser
Basically replace CMAKE_XXX_DIR with CMAKE_CURRENT_XXX_DIR where XXX = SOURCE or BINARY. Patch proposal by cleanrock, FLTK PR #4: https://github.com/fltk/test-only/pull/4 Patch modified to fix target dirs for test programs and doxygen docs. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12630 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2018-01-08MacOS + CMake: restore use of OPTION_APPLE_X11 under MacOS 10.13Manolo Gouy
It's necessary to compile with -mmacosx-version-min=10.8 and to link with -lfontconfig when Xft is used git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12627 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-12-28CMake: Fix missing WIN32 definition on Windows platforms.Albrecht Schlosser
Although some Windows compilers still #define WIN32, more and more standard compliant compilers only #define _WIN32. FLTK *did* #define WIN32 for all Windows targets with autoconf/configure, but that bit was lost for CMake builds. This is necessary until we replace WIN32 with _WIN32 throughout the Windows specific code. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12612 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-09-03Add new Fl_SVG_Image class to support scalable vector graphics images using ↵Manolo Gouy
the (modified) nanosvg software. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12413 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-07-18[CMake] Add an option to use High-DPI support (Windows only).Albrecht Schlosser
This option can be used with CMake to configure the experimental high-DPI support under Windows. The option may be removed once high-DPI support under Windows is complete. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12338 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-06-29CMake: fix potential compiler warning in test file.Albrecht Schlosser
clang reports: control reaches end of non-void function [-Wreturn-type] git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12283 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-06-29Update copyright year(s).Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12282 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-06-29CMake: replace improperly used variables with correct ones.Albrecht Schlosser
CMake variables FLTK_SOURCE_DIR and FLTK_BINARY_DIR are only defined if the project name is exactly "FLTK" (all uppercase). These variables are generated (set) by CMake as <PROJECT_NAME>_SOURCE_DIR etc. The correct variables are CMAKE_SOURCE_DIR and CMAKE_BINARY_DIR, respectively, which are always defined. This commit enables future changes of the FLTK project name, e.g. to "fltk" or "fltk-1.4.0" (a versioned project name), if we like... git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12281 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-03-17[CMake] Fix Visual Studio header detection.Albrecht Schlosser
This commit fixes a CMake issue if CMake is invoked from a desktop icon or the Windows menu, i.e. not within the correct environment to find all required header files. We recommend to run CMake from a "Developer Command Prompt for Visual Studio X", but sometimes users click on their desktop icon and run CMake without the correct context. In this case some header files in the Windows SDK's are not found by CMake. The solution is to issue a warning and "fix" the header detection by faking that the headers were found, because they are always available in Visual Studio. The affected headers <locale.h> and <GL/glu.h> were set to "found" in the bundles IDE's in FLTK 1.3 as well, so there should be no issue with this fix. It is also recommended by the CMake folks, i.e. they suggest not to search for these special header files that are known to exist always. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12209 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-03-17[CMake] Remove unused header test HAVE_GL_GL_H (GL/gl.h).Albrecht Schlosser
Note: the test for OpenGL works slightly different with CMake vs. configure. The CMake (cache) variable HAVE_GL_GL_H was never used. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12203 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2017-02-08Rename test/help demo program to test/help_dialog.Albrecht Schlosser
This change avoids a name conflict with CMake's auto-generated target 'help' for "Unix Makefiles", "Ninja", and supposedly other generators as well. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12171 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-21X11 platform: Add optional use of the pango library to draw text, gaining ↵Manolo Gouy
the possibility to draw text in any script supported by Unicode. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12153 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-06[CMake] Rewrite pthreads checks for compatibility with configure.Albrecht Schlosser
Main point: pthreads must not be checked under Windows (e.g. MinGW) since Windows always uses native Windows threads (unless Cygwin is used). git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12138 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01Add --enable-print option to configure to allow building without print ↵Manolo Gouy
support on X11 platforms. Also, the NO_PRINT_SUPPORT preprocessor variable is renamed FL_NO_PRINT_SUPPORT. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12131 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-12-01MacOS platform: restore CMake building with OPTION_APPLE_X11 on.Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.4@12128 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-08-09[CMake] Fix Windows dll build with Visual Studio generator.Albrecht Schlosser
Now you can set OPTION_BUILD_SHARED_LIBS:BOOL=ON to build FLTK dll's with Visual Studio. Tested and works (Visual Studio 2010 + 2015). Note: Linux fixes included, tested and works (Ubuntu). Todo: dll names and target directories may need some changes. We really need to get rid of that "_SHARED" suffix in .so names. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11867 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-08-05Fix CMake building under Apple platform that used to set HAVE_GL_GLU_H to 0Manolo Gouy
On the Mac OS platform, file glu.h is not in a directory called GL. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11864 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-07-09Clarification and better documentation of ABI version configuration.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11804 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-06-14THE best way to test for availability of dlsym().Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11779 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-06-13[CMake] Fix restoration of CMAKE_REQUIRED_LIBRARIES.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11777 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-06-13Fix cases where function dlysym() is not in library libdl.Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11774 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-27[CMake] Remove redundant linking in CMake build process (STR #3298).Albrecht Schlosser
[CMake] Simplify CMake build files, remove redundancies. Ports of branch-1.3, svn r 11442 and 11444: Remove src/fl_call_main.c from non-Windows (static) libraries. It would be an empty object file anyway. Use CMake variables to set up used files and linked libraries to remove redundancies. All files and libs are used only in the definition of CMake variables and used later in static and shared builds, resp. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11447 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-26[CMake] Fix library name (Debug mode), add fluid dependencies.Albrecht Schlosser
The library name in Debug mode must only be 'libname'd.a if the build is with MSVC; all other builds never appended the 'd' suffix to the name. This is also documented (see lib/README). Fluid did not regenerate the .cxx and .h files if the .fl file was changed. The DEPENDS keyword adds the necessary dependency. The MAIN_DEPENDENCY keyword "also suggests to Visual Studio generators where to hang the custom command" according to CMake docs. Ported from branch-1.3, svn r11430. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11431 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-05[CMake] Mark OPTION_USE_POLL as advanced.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11292 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-03Made Pico/SDL setup compile and run some minimal code.Matthias Melcher
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11274 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-03-02Add support for SDL as a base library on OS X.Matthias Melcher
This commit adds the basic setup in CMake to allow SDL as a base library for FLTK on OS X (and probably for other platforms as well). The SDL library driver set is derived from yet another new driver set named 'Pico'. 'Pico' is a base class for a driver that will allow porting of FLTK with the tinyest amount of effort. This implementation of the SDL driver shall be documented very well to explain the porting process. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11262 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-10More device and driver setup.Matthias Melcher
- building the base structure to have a screen driver, a window driver, and a system driver - still pondering over the exact implementation git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11147 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-10Starting CMake config to blend out filechoose and filename handling (shrins ↵Matthias Melcher
fltk massively if not needed) git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11146 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-05New CMake option OPTION_PRINT_SUPPORT turned ON by defaultManolo Gouy
When the option is off, file config.h defines NO_PRINT_SUPPORT which in turn produces a library without print support, that is, class Fl_Printer does nothing. When off, the FLTK library is somewhat smaller. Can be turned off only when the X11 library is used. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11127 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-03Support of OPTION_APPLE_X11 by CMake: do not use hard-coded pathsManolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11125 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-02To support OPTION_APPLE_X11Manolo Gouy
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11122 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-02-02Stop using ide/Xcode4/plists/editor-Info.plist because ide will be removed.Manolo Gouy
This file is moved to the test/ directory. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11120 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-01-30Bump version numbers for next minor release: FLTK 1.4.0.Albrecht Schlosser
git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11088 ea41ed52-d2ee-0310-a9c1-e6b18d33e121
2016-01-29CMake] Work around CMake bug in CMake versions 3.4.x.Albrecht Schlosser
CMake versions 3.4.x crash when using fltk_wrap_ui, a built-in CMake command. According to the CMake devs this will be fixed in CMake 3.5. However, since fltk_wrap_ui is no longer necessary (it can replaced by custom build commands) and some Linux distributions deploy CMake 3.4.x we decided to use an own replacement function. This makes sure that FLTK can be built with CMake 3.4.x, but FLTK users may still have to rewrite their own CMake files to not use fltk_wrap_ui. git-svn-id: file:///fltk/svn/fltk/branches/branch-1.3-porting@11082 ea41ed52-d2ee-0310-a9c1-e6b18d33e121