1998-10-21 01:06:19 +04:00
|
|
|
#
|
2020-09-16 13:14:22 +03:00
|
|
|
# FLUID Makefile for the Fast Light Tool Kit (FLTK).
|
1998-10-21 01:06:19 +04:00
|
|
|
#
|
2023-07-20 00:42:50 +03:00
|
|
|
# Copyright 1998-2023 by Bill Spitzak and others.
|
1998-10-21 01:06:19 +04:00
|
|
|
#
|
2011-07-19 08:49:30 +04:00
|
|
|
# This library is free software. Distribution and use rights are outlined in
|
|
|
|
# the file "COPYING" which should have been included with this file. If this
|
|
|
|
# file is missing or damaged, see the license at:
|
|
|
|
#
|
2020-07-01 19:03:10 +03:00
|
|
|
# https://www.fltk.org/COPYING.php
|
1998-10-21 01:06:19 +04:00
|
|
|
#
|
2020-07-01 19:03:10 +03:00
|
|
|
# Please see the following page on how to report bugs and issues:
|
2005-04-16 04:13:17 +04:00
|
|
|
#
|
2020-07-01 19:03:10 +03:00
|
|
|
# https://www.fltk.org/bugs.php
|
1998-10-21 01:06:19 +04:00
|
|
|
#
|
|
|
|
|
2017-02-15 23:28:13 +03:00
|
|
|
include ../makeinclude
|
|
|
|
|
1998-10-06 22:21:25 +04:00
|
|
|
CPPFILES = \
|
2005-03-21 09:28:30 +03:00
|
|
|
CodeEditor.cxx \
|
2020-09-16 19:33:24 +03:00
|
|
|
StyleParse.cxx \
|
2023-03-18 19:33:27 +03:00
|
|
|
Fd_Snap_Action.cxx \
|
2023-07-20 00:42:50 +03:00
|
|
|
Fl_Button_Type.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
Fl_Function_Type.cxx \
|
2023-10-21 14:23:11 +03:00
|
|
|
Fl_Grid_Type.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
Fl_Group_Type.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
Fl_Menu_Type.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
Fl_Type.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
Fl_Widget_Type.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
Fl_Window_Type.cxx \
|
|
|
|
Fluid_Image.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
about_panel.cxx \
|
|
|
|
align_widget.cxx \
|
|
|
|
alignment_panel.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
code.cxx \
|
2023-02-15 17:24:25 +03:00
|
|
|
custom_widgets.cxx \
|
1998-12-06 17:59:14 +03:00
|
|
|
factory.cxx \
|
|
|
|
file.cxx \
|
|
|
|
fluid.cxx \
|
2023-10-22 20:30:37 +03:00
|
|
|
fluid_filename.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
function_panel.cxx \
|
2023-10-27 00:31:12 +03:00
|
|
|
mergeback.cxx \
|
2021-12-05 01:18:21 +03:00
|
|
|
pixmaps.cxx \
|
2021-12-08 17:52:15 +03:00
|
|
|
shell_command.cxx \
|
2023-08-29 03:20:45 +03:00
|
|
|
sourceview_panel.cxx \
|
2005-03-21 00:27:20 +03:00
|
|
|
template_panel.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
undo.cxx \
|
2021-12-08 17:52:15 +03:00
|
|
|
widget_browser.cxx \
|
2005-03-20 07:00:48 +03:00
|
|
|
widget_panel.cxx
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2017-02-15 23:28:13 +03:00
|
|
|
# ExternalCodeEditor: platform specific files
|
|
|
|
|
|
|
|
CPPFILES_WIN = ExternalCodeEditor_WIN32.cxx
|
|
|
|
CPPFILES_OSX = ExternalCodeEditor_UNIX.cxx
|
|
|
|
CPPFILES_X11 = ExternalCodeEditor_UNIX.cxx
|
|
|
|
CPPFILES_XFT = ExternalCodeEditor_UNIX.cxx
|
2022-03-15 08:42:06 +03:00
|
|
|
CPPFILES_CAIRO = ExternalCodeEditor_UNIX.cxx
|
2022-03-04 18:29:18 +03:00
|
|
|
CPPFILES_WAYLAND = ExternalCodeEditor_UNIX.cxx
|
2022-09-10 08:44:23 +03:00
|
|
|
CPPFILES_WAYLANDX11 = ExternalCodeEditor_UNIX.cxx
|
2017-02-15 23:28:13 +03:00
|
|
|
|
|
|
|
CPPFILES += $(CPPFILES_$(BUILD))
|
|
|
|
|
1998-10-06 22:21:25 +04:00
|
|
|
################################################################
|
|
|
|
|
1998-12-06 17:59:14 +03:00
|
|
|
OBJECTS = $(CPPFILES:.cxx=.o)
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2002-07-14 21:03:31 +04:00
|
|
|
all: $(FLUID) fluid$(EXEEXT)
|
|
|
|
|
2008-12-29 22:45:46 +03:00
|
|
|
fluid$(EXEEXT): $(OBJECTS) $(LIBNAME) $(FLLIBNAME) \
|
|
|
|
$(IMGLIBNAME)
|
2002-07-14 21:03:31 +04:00
|
|
|
echo Linking $@...
|
2021-12-13 20:32:11 +03:00
|
|
|
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) -o $@ $(OBJECTS) $(LINKFLTKIMG) $(LDFLAGS) $(LDLIBS)
|
2021-05-13 17:16:50 +03:00
|
|
|
$(OSX_ONLY) $(RM) -r -f fluid.app
|
|
|
|
$(OSX_ONLY) mkdir -p fluid.app/Contents/MacOS fluid.app/Contents/Resources
|
2008-02-26 18:26:08 +03:00
|
|
|
$(OSX_ONLY) $(INSTALL_BIN) fluid fluid.app/Contents/MacOS
|
2021-05-13 17:16:50 +03:00
|
|
|
$(OSX_ONLY) $(INSTALL) icons/fluid.icns fluid.app/Contents/Resources
|
|
|
|
$(OSX_ONLY) $(INSTALL) fluid.plist fluid.app/Contents/Info.plist
|
2002-07-14 21:03:31 +04:00
|
|
|
|
|
|
|
fluid-shared$(EXEEXT): $(OBJECTS) ../src/$(DSONAME) ../src/$(FLDSONAME) \
|
|
|
|
../src/$(IMGDSONAME)
|
2000-04-26 02:17:00 +04:00
|
|
|
echo Linking $@...
|
2020-07-26 15:49:25 +03:00
|
|
|
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) -o $@ $(OBJECTS) $(LINKSHARED) $(LDFLAGS) $(LDLIBS)
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2005-04-16 04:01:49 +04:00
|
|
|
clean:
|
2016-02-27 20:27:21 +03:00
|
|
|
-$(RM) *.o core.* *~ *.bck *.bak
|
2005-04-16 04:01:49 +04:00
|
|
|
-$(RM) core fluid$(EXEEXT) fluid-shared$(EXEEXT)
|
2021-05-13 17:16:50 +03:00
|
|
|
$(OSX_ONLY) -$(RMDIR) fluid.app
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2001-12-19 22:23:32 +03:00
|
|
|
depend: $(CPPFILES)
|
2019-01-18 17:44:24 +03:00
|
|
|
makedepend -Y -I.. -f makedepend -w 20 $(CPPFILES)
|
|
|
|
echo "# DO NOT DELETE THIS LINE -- make depend depends on it." > makedepend.tmp
|
|
|
|
echo "" >> makedepend.tmp
|
2020-06-13 13:50:06 +03:00
|
|
|
grep '^[a-zA-Z]' makedepend | ( LC_ALL=C sort -u -f >> makedepend.tmp; )
|
2019-01-18 17:44:24 +03:00
|
|
|
mv makedepend.tmp makedepend
|
2001-08-02 19:32:00 +04:00
|
|
|
|
2002-03-28 16:20:11 +03:00
|
|
|
# Automatically generated dependencies...
|
1998-10-06 22:21:25 +04:00
|
|
|
include makedepend
|
|
|
|
|
2006-01-15 18:15:34 +03:00
|
|
|
install: all
|
2004-10-19 00:22:25 +04:00
|
|
|
echo "Installing FLUID in $(DESTDIR)$(bindir)..."
|
2007-02-06 22:35:28 +03:00
|
|
|
-$(INSTALL_DIR) $(DESTDIR)$(bindir)
|
|
|
|
$(INSTALL_BIN) $(FLUID) $(DESTDIR)$(bindir)/fluid$(EXEEXT)
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2006-01-15 06:16:09 +03:00
|
|
|
install-linux:
|
2008-02-25 17:43:34 +03:00
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/usr/share/applications
|
|
|
|
$(INSTALL_DATA) fluid.desktop $(DESTDIR)/usr/share/applications
|
2006-01-15 06:16:09 +03:00
|
|
|
for size in 16 32 48 64 128; do \
|
2006-01-15 21:02:44 +03:00
|
|
|
if test ! -d $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; then \
|
2007-02-06 22:35:28 +03:00
|
|
|
$(INSTALL_DIR) $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps; \
|
2006-01-15 21:02:44 +03:00
|
|
|
fi; \
|
2007-02-06 22:35:28 +03:00
|
|
|
$(INSTALL_DATA) icons/fluid-$$size.png $(DESTDIR)/usr/share/icons/hicolor/$${size}x$${size}/apps/fluid.png; \
|
2006-01-15 06:16:09 +03:00
|
|
|
done
|
2007-02-06 22:35:28 +03:00
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/usr/share/mimelnk/application
|
|
|
|
$(INSTALL_DATA) x-fluid.desktop $(DESTDIR)/usr/share/mimelnk/application
|
2006-01-15 06:16:09 +03:00
|
|
|
|
|
|
|
install-osx:
|
2006-08-30 14:01:35 +04:00
|
|
|
echo Installing Fluid in $(DESTDIR)/Applications...
|
2007-02-06 22:35:28 +03:00
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app
|
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents
|
|
|
|
$(INSTALL_DATA) fluid.app/Contents/Info.plist $(DESTDIR)/Applications/fluid.app/Contents/Info.plist
|
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents/MacOS
|
|
|
|
$(RM) $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
|
2006-08-30 14:01:35 +04:00
|
|
|
$(LN) $(bindir)/fluid $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
|
2007-02-06 22:35:28 +03:00
|
|
|
-$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents/Resources
|
|
|
|
$(INSTALL_DATA) fluid.app/Contents/Resources/fluid.icns $(DESTDIR)/Applications/fluid.app/Contents/Resources
|
2006-01-15 06:16:09 +03:00
|
|
|
|
2006-01-15 18:15:34 +03:00
|
|
|
uninstall:
|
2004-10-19 00:22:25 +04:00
|
|
|
$(RM) $(DESTDIR)$(bindir)/fluid$(EXEEXT)
|
1998-10-06 22:21:25 +04:00
|
|
|
|
2006-01-15 06:16:09 +03:00
|
|
|
uninstall-linux:
|
2008-02-25 17:43:34 +03:00
|
|
|
$(RM) $(DESTDIR)/usr/share/applications/fluid.desktop
|
2006-01-15 06:16:09 +03:00
|
|
|
$(RM) $(DESTDIR)/usr/share/icons/hicolor/*/fluid.png
|
|
|
|
$(RM) $(DESTDIR)/usr/share/mimelnk/application/x-fluid.desktop
|
|
|
|
|
|
|
|
uninstall-osx:
|
|
|
|
$(RM) -r $(DESTDIR)/Applications/fluid.app
|
|
|
|
|
1998-10-21 21:24:51 +04:00
|
|
|
# Note: The rebuild target can only be used if you have the original .fl
|
2020-09-16 13:14:22 +03:00
|
|
|
# files. This is normally only used by the FLTK maintainers...
|
|
|
|
# It *must* be executed *after* fluid has been built and
|
|
|
|
# fluid must be rebuilt if any {.fl|.cxx|.h} files were changed.
|
|
|
|
|
|
|
|
rebuild: fluid$(EXEEXT)
|
|
|
|
echo 'Rebuilding fluid (.fl) and .cxx/.h files from .fl files ...'
|
|
|
|
./fluid$(EXEEXT) -u -c about_panel.fl
|
|
|
|
./fluid$(EXEEXT) -u -c alignment_panel.fl
|
|
|
|
./fluid$(EXEEXT) -u -c function_panel.fl
|
|
|
|
./fluid$(EXEEXT) -u -c print_panel.fl
|
2023-08-29 03:20:45 +03:00
|
|
|
./fluid$(EXEEXT) -u -c sourceview_panel.fl
|
2020-09-16 13:14:22 +03:00
|
|
|
./fluid$(EXEEXT) -u -c template_panel.fl
|
|
|
|
./fluid$(EXEEXT) -u -c widget_panel.fl
|