Option to specify applications directory

38 views
Skip to first unread message

Dave Allured - NOAA Affiliate

unread,
Jul 27, 2025, 3:39:02 AMJul 27
to fltk.general
in FLTK 1.4.4, /Applications is hard coded in several make files.  Please change this to $(applications_dir), defaulting to /Applications,. with a configure option to change it.  The purpose is to support custom $prefix installations.  Thank you.

Albrecht Schlosser

unread,
Jul 27, 2025, 6:27:48 AMJul 27
to fltkg...@googlegroups.com
Hi Dave, thanks for your request. Unfortunately FLTK 1.4 is in
maintenance mode (end of active development) and receives only bug fixes
and some selected backports from 1.5 development. There are no plans to
change configure/Makefiles in 1.4 because configure/make support will be
dropped in the next minor release (1.5.0). It has already been removed
from 1.5 (git).

That said, I can see two (or even three) options for what you likely
want to achieve:

1. With configure you can use the DESTDIR environment variable to
install to a custom prefix, although this still uses the /Applications
folder as in "$(DESTDIR)/Applications/...".

2. You can use CMake to build and install FLTK, for a start please see
README.CMake.txt. With CMake you can use the CMake variable
`CMAKE_INSTALL_PREFIX` to change the installation prefix.

3. You can use FLTK directly from its build folder which is particularly
useful if you build with CMake. CMake can use out-of-tree builds, i.e.
the build folder can be any folder on your system which not be related
to the source folder. Theoretically you can delete the source tree after
building.

We recommend everybody to use CMake to build FLTK 1.4.x to be prepared
for 1.5 where configure will no longer be available. Building FLTK with
CMake is particularly useful if you also build your own application(s)
with CMake.

I hope this helps. If you have further questions, please feel free to
ask ...

Dave Allured - NOAA Affiliate

unread,
Jul 27, 2025, 9:35:49 AMJul 27
to fltk.general
@Albrecht-S  Thank you for your prompt reply.  Please let me clarify.  I am not trying to change $prefix.  I already know how to use that.  I am trying to change only the currently hard coded subfolder "/Applications" to a different path, in support of alternative configurations.  Also I now understand that configure/make support is dropped in 1.5 onward.

I do not find any discussion of the /Applications folder in any README or CMake file, anywhere in the current 1.5 snapshot.  I will simply request that if FLTK wants to install any app or component into /Applications on Mac, then please provide some way to configure that subfolder path to something different.  Thanks.

Manolo

unread,
Jul 27, 2025, 12:14:50 PMJul 27
to fltk.general
Could you, please, specify what are the
        currently hard coded subfolder "/Applications" 
you write about? Searching for that string in all of the FLTK source code, I find none that may be relevant.



Dave Allured - NOAA Affiliate

unread,
Jul 27, 2025, 1:09:39 PMJul 27
to fltk.general
@Manolo I am testing with FLTK 1.4.4 because it is the current stable release, released only 1 week ago.  In 1.4.4 you should find $(DESTDIR)/Applications hard coded in several make files.  Yes I noticed that /Applications is completely absent from the current 1.5 development version. My 1.4.4 generic installation tries to install these five apps. The last three are coming from a generating loop in test/Makefile:

    /Applications/fltk-options.app
    /Applications/fluid.app
    /Applications/blocks.app
    /Applications/checkers.app
    /Applications/sudoku.app

Manolo

unread,
Jul 28, 2025, 1:40:28 AMJul 28
to fltk.general
In FLTK 1.4.4 built with configure, "/Applications" is only used at the install step to copy to that folder these FLTK apps:
fluid, fltk-options, blocks, checkers, sudoku.

Would this other approach suit your demands?
- configure and build FLTK 1.4.4 as you do normally
- don't perform the "make install" step
- move or copy yourself where it suits you these apps:
fluid/fluid.app
fltk-options/fltk-options.app

Dave Allured - NOAA Affiliate

unread,
Jul 28, 2025, 10:19:05 AMJul 28
to fltk.general
@Manolo thank you for the suggestion.  I solved my current problem in 1.4.4 by patching three make files.  My request is relevant only for future FLTK releases.  If FLTK wants to install any app or component into /Applications on Mac in future releases, then please provide some way to configure that subfolder path to something different.

Manolo

unread,
Jul 30, 2025, 2:37:49 AMJul 30
to fltk.general


Le lundi 28 juillet 2025 à 16:19:05 UTC+2, dave.a...@noaa.gov a écrit :
……  If FLTK wants to install any app or component into /Applications on Mac in future releases, then please provide some way to configure that subfolder path to something different.

As Albrecht previously wrote here, future FLTK releases will be for the 1.5.x series and will require CMake for
their build process. This process allows to use CMake option CMAKE_INSTALL_PREFIX to specify a directory
where product and library files are to be installed. I've just checked that, if using CMAKE_INSTALL_PREFIX,
the 5 applications discussed above no longer go to /Applications. They get installed in the bin subdirectory of the directory
specified by the CMAKE_INSTALL_PREFIX option.

Therefore, I believe your request to be already in place.

Dave Allured - NOAA Affiliate

unread,
Jul 30, 2025, 10:42:47 AMJul 30
to fltk.general
On Wednesday, July 30, 2025 at 12:37:49 AM UTC-6 Manolo wrote:
As Albrecht previously wrote here, future FLTK releases will be for the 1.5.x series and will require CMake for
their build process. This process allows to use CMake option CMAKE_INSTALL_PREFIX to specify a directory
where product and library files are to be installed. I've just checked that, if using CMAKE_INSTALL_PREFIX,
the 5 applications discussed above no longer go to /Applications. They get installed in the bin subdirectory of the directory
specified by the CMAKE_INSTALL_PREFIX option.

Therefore, I believe your request to be already in place.

@Manolo  Now I understand.  That satisfies my concern for 1.5.x.  If it should ever be desirable to return to /Applications in the future, then I merely suggest that a distinct configuration option for $(applications_dir) should be introduced.  This would allow staging or rebasing of /Applications, independently from CMAKE_INSTALL_PREFIX, if ever needed.  This is not anything that I need installed in 1.5.x at this time.
Reply all
Reply to author
Forward
0 new messages