Browse Source

Restore build of fteapot (on OpenSUSE Tumbleweed)

Changes to CMakeLists.txt to allow the system fltk to be found. These may
  have interfered with static linking, as now the command lines for static
  and dynamic linking look identical.

  A small change to fteapot.fl so that the resulting code will compile.

  Some additions to the INSTALL file to help point to prerequisites.

  Fixes #1.
master
Glen Whitney 2 years ago
parent
commit
eefc54818c
  1. 8
      CMakeLists.txt
  2. 20
      INSTALL
  3. 3
      fteapot.fl

8
CMakeLists.txt

@ -45,10 +45,8 @@ if (CURSES_FOUND)
install(TARGETS teapot DESTINATION bin)
endif ()
find_package(FLTK NO_MODULE)
find_package(FLTK)
if (FLTK_FOUND)
include("${FLTK_USE_FILE}")
fltk_wrap_ui(fteapot fteapot.fl)
add_executable(fteapot WIN32 ${fteapot_FLTK_UI_SRCS})
set(fteapot_DEB_DEPENDS ", libstdc++6 (>= 4.1.1), libfltk1.3")
@ -57,13 +55,13 @@ if (FLTK_FOUND)
if (ENABLE_STATIC)
target_link_libraries(fteapot teapotlib fltk fltk_images ${LIB_PORTABLEXDR})
else ()
target_link_libraries(fteapot teapotlib fltk_SHARED fltk_images_SHARED ${LIB_PORTABLEXDR})
target_link_libraries(fteapot teapotlib fltk fltk_images ${LIB_PORTABLEXDR})
endif ()
else ()
if (ENABLE_STATIC)
target_link_libraries(fteapot teapotlib fltk fltk_images ${LIB_PORTABLEXDR})
else ()
target_link_libraries(fteapot teapotlib fltk_SHARED ${LIB_PORTABLEXDR})
target_link_libraries(fteapot teapotlib fltk ${LIB_PORTABLEXDR})
endif ()
endif ()
install(TARGETS fteapot DESTINATION bin)

20
INSTALL

@ -1,19 +1,25 @@
The new build system uses CMake (http://www.cmake.org). It handles
all platform differences.
See the README for required third-party libraries.
In addition to the information in the README.md file on prerequisites, here
are some additional guidelines:
The XDR functions are no longer in the GNU library, so you will need an
additional package to supply them. The README.md suggests one; another is
tirpc. This is available on OpenSUSE, for example, via
zypper install libtirpc-devel.
The documentation can only be built if you have latex2html (version
2008), pdflatex and lyx installed. If you don't, turn off the
ENABLE_HELP option (using the ccmake command or any other CMake
frontend).
Note that the GUI version definitely needs FLTK-1.3, so you may need
to download and build an SVN snapshot. SVN r7704 was used for development.
You MUST use CMake to configure FLTK, not "./configure". You don't need
to install it, as FLTK is so small that statically linking it (the default)
is safe. If you don't install FLTK, set the path to your FLTK directory
using ccmake.
Note that the GUI version definitely needs FLTK-1.3. CMake apparently finds
a system-installed version of this without difficulty. However, it is not
entirely clear if static linking, should you prefer it, will work properly
with the current setup. One possibility is to build FLTK yourself and ensure
that your own version is found before the system one; that should allow static
linking.
For the console version you will have to make sure your system
offers a SYSV compatible curses. You can check that you do by looking

3
fteapot.fl

@ -2,6 +2,9 @@
version 1.0300
header_name {.h}
code_name {.cxx}
decl {\#include <unistd.h>} {private global
}
decl {\#include <stdint.h>} {private global
}

Loading…
Cancel
Save