summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlbrecht Schlosser <albrechts.fltk@online.de>2021-05-13 16:16:50 +0200
committerAlbrecht Schlosser <albrechts.fltk@online.de>2021-05-13 16:18:13 +0200
commit773467dee4e79e0dfd97c5ee98fc253dead3302c (patch)
tree9ac93d67a1ed19257de461aa0089b4b521ed7c69
parent64296707d9e9b38dd9addf655f9b0943a4c54a54 (diff)
Refactor macOS bundle generation to avoid "quarantine"
macOS Big Sur 11.3 introduced a new "security feature" such that app bundles created from existing bundle templates in downloaded files (tar distibutions, expanded) could no longer be executed without unsetting the "quarantine" attribute. This commit fixes this by creating all bundles from scratch. Known *workaround* for older tarballs and snapshots: $ xattr -d -r com.apple.quarantine xxx.app
-rw-r--r--.gitignore10
-rw-r--r--CMake/fl_create_example.cmake29
-rw-r--r--fltk.list.in4
-rw-r--r--fluid/CMakeLists.txt4
-rw-r--r--fluid/Makefile11
-rw-r--r--fluid/fluid.app/Contents/PkgInfo1
-rw-r--r--fluid/fluid.plist (renamed from fluid/fluid.app/Contents/Info.plist)0
-rw-r--r--fluid/icons/fluid.icns (renamed from fluid/fluid.app/Contents/Resources/fluid.icns)bin34579 -> 34579 bytes
-rw-r--r--test/.gitignore84
-rw-r--r--test/CMakeLists.txt8
-rw-r--r--test/Makefile57
-rw-r--r--test/blocks.app/Contents/PkgInfo1
-rw-r--r--test/checkers.app/Contents/PkgInfo1
-rw-r--r--test/mac-resources/blocks.icns (renamed from test/blocks.app/Contents/Resources/blocks.icns)bin51049 -> 51049 bytes
-rw-r--r--test/mac-resources/blocks.plist (renamed from test/blocks.app/Contents/Info.plist)6
-rw-r--r--test/mac-resources/checkers.icns (renamed from test/checkers.app/Contents/Resources/checkers.icns)bin61235 -> 61235 bytes
-rw-r--r--test/mac-resources/checkers.plist (renamed from test/checkers.app/Contents/Info.plist)6
-rw-r--r--test/mac-resources/editor.plist (renamed from test/editor-Info.plist)2
-rw-r--r--test/mac-resources/sudoku.icns (renamed from test/sudoku.app/Contents/Resources/sudoku.icns)bin34921 -> 34921 bytes
-rw-r--r--test/mac-resources/sudoku.plist (renamed from test/sudoku.app/Contents/Info.plist)4
-rw-r--r--test/sudoku.app/Contents/PkgInfo1
21 files changed, 57 insertions, 172 deletions
diff --git a/.gitignore b/.gitignore
index 7685448a1..21d2cd16b 100644
--- a/.gitignore
+++ b/.gitignore
@@ -97,11 +97,7 @@ etc/FLTKConfig.cmake
/fluid/*.bck
/fluid/*.exe
/fluid/TAGS
-
-# /fluid/fluid.app/Contents/MacOS/
-/fluid/fluid.app/Contents/MacOS/fluid
-
-# /fluid/pixmaps/
+/fluid/fluid.app
/fluid/pixmaps/*.bck
# /lib/
@@ -124,8 +120,4 @@ etc/FLTKConfig.cmake
# /test/
# see test/.gitignore
-# macOS binary files
-# (see also test/.gitignore)
-
-fluid/*.app/Contents/MacOS
**/.DS_Store
diff --git a/CMake/fl_create_example.cmake b/CMake/fl_create_example.cmake
index 8071b5070..22c418bc6 100644
--- a/CMake/fl_create_example.cmake
+++ b/CMake/fl_create_example.cmake
@@ -27,7 +27,7 @@
# Sources can be:
# - .c/.cxx files, e.g. 'hello.cxx'
# - .fl (fluid) files, e.g. 'radio.fl'
-# - .plist file (macOS), e.g. 'editor-Info.plist'
+# - .plist file (macOS), e.g. 'editor.plist'
# - .icns file (macOS Icon), e.g. 'checkers.icns'
# - .rc file (Windows resource file, e.g. icon definition)
#
@@ -39,10 +39,11 @@
# all other file types are added to the target's source files.
#
# macOS specific .icns and .plist files are ignored on other platforms.
+# These files must reside in the subdirectory 'mac-resources'.
#
# - LIBRARIES:
# List of libraries (CMake target names), separated by ';'. Needs
-# quotes if more than one library is needed, e.g. "fltk_gl;fltk"
+# quotes if more than one library is required, e.g. "fltk_gl;fltk"
#
# CREATE_EXAMPLE can have an optional fourth argument with a list of options
# - the option ANDROID_OK is set if CREATE_EXAMPLE creates code for Android
@@ -99,7 +100,7 @@ macro (CREATE_EXAMPLE NAME SOURCES LIBRARIES)
# set macOS (icon) resource path if applicable
if (MAC_BUNDLE AND ICON_NAME)
- set (ICON_PATH "${CMAKE_CURRENT_SOURCE_DIR}/${TARGET_NAME}.app/Contents/Resources/${ICON_NAME}")
+ set (ICON_PATH "${CMAKE_CURRENT_SOURCE_DIR}/mac-resources/${ICON_NAME}")
endif (MAC_BUNDLE AND ICON_NAME)
##############################################################################
@@ -109,7 +110,7 @@ macro (CREATE_EXAMPLE NAME SOURCES LIBRARIES)
if (MAC_BUNDLE)
add_executable (${TARGET_NAME} MACOSX_BUNDLE ${srcs} ${ICON_PATH})
else ()
- add_executable (${TARGET_NAME} WIN32 ${srcs} ${ICON_PATH})
+ add_executable (${TARGET_NAME} WIN32 ${srcs})
endif (MAC_BUNDLE)
set_target_properties (${TARGET_NAME} PROPERTIES OUTPUT_NAME ${NAME})
@@ -123,16 +124,19 @@ macro (CREATE_EXAMPLE NAME SOURCES LIBRARIES)
endif()
endif (FLTK_HAVE_CAIRO)
- if (ICON_PATH)
- set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_ICON_FILE ${ICON_NAME})
- set_target_properties (${TARGET_NAME} PROPERTIES RESOURCE ${ICON_PATH})
- endif (ICON_PATH)
+ if (MAC_BUNDLE)
+ if (PLIST)
+ set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_INFO_PLIST
+ "${CMAKE_CURRENT_SOURCE_DIR}/mac-resources/${PLIST}")
+ endif()
- if (PLIST)
- set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_INFO_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/${PLIST}")
- elseif (MAC_BUNDLE)
set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_BUNDLE_NAME "${TARGET_NAME}")
set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_GUI_IDENTIFIER "org.fltk.${TARGET_NAME}")
+
+ if (ICON_NAME)
+ set_target_properties (${TARGET_NAME} PROPERTIES MACOSX_BUNDLE_ICON_FILE ${ICON_NAME})
+ set_target_properties (${TARGET_NAME} PROPERTIES RESOURCE ${ICON_PATH})
+ endif ()
endif ()
##############################################################################
@@ -142,9 +146,10 @@ macro (CREATE_EXAMPLE NAME SOURCES LIBRARIES)
if (MAC_BUNDLE)
set (WRAPPER "${EXECUTABLE_OUTPUT_PATH}/${CMAKE_CFG_INTDIR}/${TARGET_NAME}")
+
add_custom_command (
TARGET ${TARGET_NAME} POST_BUILD
- COMMAND cp ${CMAKE_CURRENT_SOURCE_DIR}/../CMake/macOS-bundle-wrapper.in ${WRAPPER}
+ COMMAND cp ${FLTK_SOURCE_DIR}/CMake/macOS-bundle-wrapper.in ${WRAPPER}
COMMAND chmod u+x,g+x,o+x ${WRAPPER}
BYPRODUCTS ${WRAPPER}
# COMMENT "Creating macOS bundle wrapper script ${WRAPPER}"
diff --git a/fltk.list.in b/fltk.list.in
index 89c61426b..f9fbab030 100644
--- a/fltk.list.in
+++ b/fltk.list.in
@@ -107,7 +107,6 @@ f 0555 root sys $libdir/libfltk_gl.so.@FL_DSO_VERSION@ src/libfltk_gl.so.@FL_DSO
d 0555 root sys /Applications/fluid.app -
d 0555 root sys /Applications/fluid.app/Contents -
f 0444 root sys /Applications/fluid.app/Contents/Info.plist fluid/fluid.app/Contents/Info.plist
-f 0444 root sys /Applications/fluid.app/Contents/PkgInfo fluid/fluid.app/Contents/PkgInfo
d 0555 root sys /Applications/fluid.app/Contents/MacOS -
l 0555 root sys /Applications/fluid.app/Contents/MacOS/fluid $bindir/fluid
d 0555 root sys /Applications/fluid.app/Contents/Resources -
@@ -376,7 +375,6 @@ f 0444 root sys $docdir/examples/ test/*.h
d 0555 root sys /Applications/blocks.app -
d 0555 root sys /Applications/blocks.app/Contents -
f 0444 root sys /Applications/blocks.app/Contents/Info.plist test/blocks.app/Contents/Info.plist
-f 0444 root sys /Applications/blocks.app/Contents/PkgInfo test/blocks.app/Contents/PkgInfo
d 0555 root sys /Applications/blocks.app/Contents/MacOS -
f 0555 root sys /Applications/blocks.app/Contents/MacOS/blocks test/blocks
d 0555 root sys /Applications/blocks.app/Contents/Resources -
@@ -386,7 +384,6 @@ f 0444 root sys /Applications/blocks.app/Contents/Resources/blocks.icns test/blo
d 0555 root sys /Applications/checkers.app -
d 0555 root sys /Applications/checkers.app/Contents -
f 0444 root sys /Applications/checkers.app/Contents/Info.plist test/checkers.app/Contents/Info.plist
-f 0444 root sys /Applications/checkers.app/Contents/PkgInfo test/checkers.app/Contents/PkgInfo
d 0555 root sys /Applications/checkers.app/Contents/MacOS -
f 0555 root sys /Applications/checkers.app/Contents/MacOS/checkers test/checkers
d 0555 root sys /Applications/checkers.app/Contents/Resources -
@@ -396,7 +393,6 @@ f 0444 root sys /Applications/checkers.app/Contents/Resources/checkers.icns test
d 0555 root sys /Applications/sudoku.app -
d 0555 root sys /Applications/sudoku.app/Contents -
f 0444 root sys /Applications/sudoku.app/Contents/Info.plist test/sudoku.app/Contents/Info.plist
-f 0444 root sys /Applications/sudoku.app/Contents/PkgInfo test/sudoku.app/Contents/PkgInfo
d 0555 root sys /Applications/sudoku.app/Contents/MacOS -
f 0555 root sys /Applications/sudoku.app/Contents/MacOS/sudoku test/sudoku
d 0555 root sys /Applications/sudoku.app/Contents/Resources -
diff --git a/fluid/CMakeLists.txt b/fluid/CMakeLists.txt
index 73cdb4528..48df3eed8 100644
--- a/fluid/CMakeLists.txt
+++ b/fluid/CMakeLists.txt
@@ -49,7 +49,7 @@ endif (WIN32)
if (APPLE AND (NOT OPTION_APPLE_X11) AND (NOT OPTION_APPLE_SDL))
set (ICON_NAME fluid.icns)
- set (ICON_PATH "${PROJECT_SOURCE_DIR}/fluid/fluid.app/Contents/Resources/${ICON_NAME}")
+ set (ICON_PATH "${CMAKE_CURRENT_SOURCE_DIR}/icons/${ICON_NAME}")
add_executable (fluid MACOSX_BUNDLE ${CPPFILES} ${ICON_PATH})
# create macOS bundle wrapper script
@@ -82,7 +82,7 @@ endif (FLTK_HAVE_CAIRO)
if (APPLE AND (NOT OPTION_APPLE_X11) AND (NOT OPTION_APPLE_SDL))
# create bundle
- set_target_properties (fluid PROPERTIES MACOSX_BUNDLE_INFO_PLIST "${PROJECT_SOURCE_DIR}/fluid/fluid.app/Contents/Info.plist")
+ set_target_properties (fluid PROPERTIES MACOSX_BUNDLE_INFO_PLIST "${CMAKE_CURRENT_SOURCE_DIR}/fluid.plist")
set_target_properties (fluid PROPERTIES MACOSX_BUNDLE_ICON_FILE ${ICON_NAME})
set_target_properties (fluid PROPERTIES RESOURCE ${ICON_PATH})
# install
diff --git a/fluid/Makefile b/fluid/Makefile
index a4656be46..7d946cb80 100644
--- a/fluid/Makefile
+++ b/fluid/Makefile
@@ -1,7 +1,7 @@
#
# FLUID Makefile for the Fast Light Tool Kit (FLTK).
#
-# Copyright 1998-2020 by Bill Spitzak and others.
+# Copyright 1998-2021 by Bill Spitzak and others.
#
# 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
@@ -57,9 +57,11 @@ fluid$(EXEEXT): $(OBJECTS) $(LIBNAME) $(FLLIBNAME) \
$(IMGLIBNAME)
echo Linking $@...
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) -o $@ $(OBJECTS) $(LINKFLTKFORMS) $(LINKFLTKIMG) $(LDFLAGS) $(LDLIBS)
- $(OSX_ONLY) $(RM) -r -f fluid.app/Contents/MacOS
- $(OSX_ONLY) mkdir fluid.app/Contents/MacOS
+ $(OSX_ONLY) $(RM) -r -f fluid.app
+ $(OSX_ONLY) mkdir -p fluid.app/Contents/MacOS fluid.app/Contents/Resources
$(OSX_ONLY) $(INSTALL_BIN) fluid fluid.app/Contents/MacOS
+ $(OSX_ONLY) $(INSTALL) icons/fluid.icns fluid.app/Contents/Resources
+ $(OSX_ONLY) $(INSTALL) fluid.plist fluid.app/Contents/Info.plist
fluid-shared$(EXEEXT): $(OBJECTS) ../src/$(DSONAME) ../src/$(FLDSONAME) \
../src/$(IMGDSONAME)
@@ -69,7 +71,7 @@ fluid-shared$(EXEEXT): $(OBJECTS) ../src/$(DSONAME) ../src/$(FLDSONAME) \
clean:
-$(RM) *.o core.* *~ *.bck *.bak
-$(RM) core fluid$(EXEEXT) fluid-shared$(EXEEXT)
- -$(RM) fluid.app/Contents/MacOS/fluid$(EXEEXT)
+ $(OSX_ONLY) -$(RMDIR) fluid.app
depend: $(CPPFILES)
makedepend -Y -I.. -f makedepend -w 20 $(CPPFILES)
@@ -103,7 +105,6 @@ install-osx:
-$(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_DATA) fluid.app/Contents/PkgInfo $(DESTDIR)/Applications/fluid.app/Contents/PkgInfo
-$(INSTALL_DIR) $(DESTDIR)/Applications/fluid.app/Contents/MacOS
$(RM) $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
$(LN) $(bindir)/fluid $(DESTDIR)/Applications/fluid.app/Contents/MacOS/fluid
diff --git a/fluid/fluid.app/Contents/PkgInfo b/fluid/fluid.app/Contents/PkgInfo
deleted file mode 100644
index c5f93635d..000000000
--- a/fluid/fluid.app/Contents/PkgInfo
+++ /dev/null
@@ -1 +0,0 @@
-FLIDFlid
diff --git a/fluid/fluid.app/Contents/Info.plist b/fluid/fluid.plist
index 4f0333f0a..4f0333f0a 100644
--- a/fluid/fluid.app/Contents/Info.plist
+++ b/fluid/fluid.plist
diff --git a/fluid/fluid.app/Contents/Resources/fluid.icns b/fluid/icons/fluid.icns
index 0fda05512..0fda05512 100644
--- a/fluid/fluid.app/Contents/Resources/fluid.icns
+++ b/fluid/icons/fluid.icns
Binary files differ
diff --git a/test/.gitignore b/test/.gitignore
index cb9e85b0d..e11a9a2ca 100644
--- a/test/.gitignore
+++ b/test/.gitignore
@@ -132,86 +132,4 @@ windowfocus
# macOS binary files
-# (a) bundles *partially* in Git: ignore executables only
-
-blocks.app/Contents/MacOS/blocks
-checkers.app/Contents/MacOS/checkers
-sudoku.app/Contents/MacOS/sudoku
-
-# (b) other bundles created by in-source builds
-
-adjuster.app
-animated.app
-arc.app
-ask.app
-bitmap.app
-boxtype.app
-browser.app
-button.app
-buttons.app
-cairo_test.app
-clock.app
-colbrowser.app
-color_chooser.app
-cube.app
-CubeView.app
-cursor.app
-curve.app
-demo.app
-device.app
-doublebuffer.app
-editor.app
-fast_slow.app
-file_chooser.app
-fonts.app
-forms.app
-fractals.app
-fullscreen.app
-gl_overlay.app
-glpuzzle.app
-hello.app
-help_dialog.app
-icon.app
-iconize.app
-image.app
-inactive.app
-input.app
-input_choice.app
-keyboard.app
-label.app
-line_style.app
-list_visuals.app
-mandelbrot.app
-menubar.app
-message.app
-minimum.app
-native-filechooser.app
-navigation.app
-offscreen.app
-output.app
-overlay.app
-pack.app
-pixmap.app
-pixmap_browser.app
-preferences.app
-radio.app
-resize.app
-resize-example*.app
-resizebox.app
-rotated_text.app
-scroll.app
-shape.app
-subwindow.app
-symbols.app
-table.app
-tabs.app
-tabs.app/Contents
-threads.app
-tile.app
-tiled_image.app
-tree.app
-twowin.app
-unittests.app
-utf8.app
-valuators.app
-windowfocus.app
+*.app
diff --git a/test/CMakeLists.txt b/test/CMakeLists.txt
index 7341de886..9c602ce7a 100644
--- a/test/CMakeLists.txt
+++ b/test/CMakeLists.txt
@@ -1,7 +1,7 @@
#
# CMakeLists.txt used to build test and demo apps by the CMake build system
#
-# Copyright 2004-2020 by Bill Spitzak and others.
+# Copyright 2004-2021 by Bill Spitzak and others.
#
# 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
@@ -57,7 +57,7 @@ CREATE_EXAMPLE (arc arc.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (animated animated.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (ask ask.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (bitmap bitmap.cxx fltk ANDROID_OK)
-CREATE_EXAMPLE (blocks "blocks.cxx;blocks.icns" "fltk;${AUDIOLIBS}")
+CREATE_EXAMPLE (blocks "blocks.cxx;blocks.plist;blocks.icns" "fltk;${AUDIOLIBS}")
CREATE_EXAMPLE (boxtype boxtype.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (browser browser.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (button button.cxx fltk ANDROID_OK)
@@ -71,7 +71,7 @@ CREATE_EXAMPLE (curve curve.cxx fltk ANDROID_OK)
CREATE_EXAMPLE (demo demo.cxx fltk)
CREATE_EXAMPLE (device device.cxx "fltk_images;fltk")
CREATE_EXAMPLE (doublebuffer doublebuffer.cxx fltk ANDROID_OK)
-CREATE_EXAMPLE (editor "editor.cxx;editor-Info.plist" fltk ANDROID_OK)
+CREATE_EXAMPLE (editor "editor.cxx;editor.plist" fltk ANDROID_OK)
CREATE_EXAMPLE (fast_slow fast_slow.fl fltk ANDROID_OK)
CREATE_EXAMPLE (file_chooser file_chooser.cxx "fltk_images;fltk")
CREATE_EXAMPLE (fltk-versions fltk-versions.cxx fltk)
@@ -120,7 +120,7 @@ CREATE_EXAMPLE (resize-example4b "resize-example4b.cxx;resize-arrows.cxx" fltk)
CREATE_EXAMPLE (rotated_text rotated_text.cxx fltk)
CREATE_EXAMPLE (scroll scroll.cxx fltk)
CREATE_EXAMPLE (subwindow subwindow.cxx fltk)
-CREATE_EXAMPLE (sudoku "sudoku.cxx;sudoku.icns;sudoku.rc" "fltk_images;fltk;${AUDIOLIBS}")
+CREATE_EXAMPLE (sudoku "sudoku.cxx;sudoku.plist;sudoku.icns;sudoku.rc" "fltk_images;fltk;${AUDIOLIBS}")
CREATE_EXAMPLE (symbols symbols.cxx fltk)
CREATE_EXAMPLE (tabs tabs.fl fltk)
CREATE_EXAMPLE (table table.cxx fltk)
diff --git a/test/Makefile b/test/Makefile
index b3f213119..e7f71af46 100644
--- a/test/Makefile
+++ b/test/Makefile
@@ -1,7 +1,7 @@
#
-# Test/example program makefile for the Fast Light Tool Kit (FLTK).
+# Test/example program Makefile for the Fast Light Tool Kit (FLTK).
#
-# Copyright 1998-2020 by Bill Spitzak and others.
+# Copyright 1998-2021 by Bill Spitzak and others.
#
# 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
@@ -208,35 +208,9 @@ depend: $(CPPFILES)
# Automatically generated dependencies...
include makedepend
-# Additional dependencies...
-cairo_test.o: ../FL/Fl_Bitmap.H
-cairo_test.o: ../FL/Fl_Box.H
-cairo_test.o: ../FL/Fl_Cairo_Window.H
-cairo_test.o: ../FL/Fl_Device.H
-cairo_test.o: ../FL/Fl_Double_Window.H
-cairo_test.o: ../FL/fl_draw.H
-cairo_test.o: ../FL/Fl_Graphics_Driver.H
-cairo_test.o: ../FL/Fl_Group.H
-cairo_test.o: ../FL/Fl.H
-cairo_test.o: ../FL/Fl_Image.H
-cairo_test.o: ../FL/Fl_Pixmap.H
-cairo_test.o: ../FL/Fl_Plugin.H
-cairo_test.o: ../FL/Fl_Preferences.H
-cairo_test.o: ../FL/Fl_RGB_Image.H
-cairo_test.o: ../FL/fl_utf8.h
-cairo_test.o: ../FL/Fl_Widget.H
-cairo_test.o: ../FL/Fl_Window.H
-cairo_test.o: ../FL/math.h
-cairo_test.o: ../FL/platform.H
-
clean:
$(RM) $(ALL) $(GLALL) core
- for file in $(ALL) $(GLALL); do \
- if [ $$file = "blocks" -o $$file = "checkers" -o $$file = "sudoku" ]; then \
- continue; \
- fi; \
- $(OSX_ONLY) rm -f -r $$file.app; \
- done
+ $(RMDIR) *.app
$(RM) *.o core.* *~ *.bck *.bak
$(RM) CubeViewUI.cxx CubeViewUI.h
$(RM) checkers_pieces.cxx checkers_pieces.h
@@ -250,9 +224,6 @@ clean:
$(RM) tabs.cxx tabs.h
$(RM) tree.cxx tree.h
$(RM) valuators.cxx valuators.h
- $(OSX_ONLY) $(RM) blocks.app/Contents/MacOS/blocks$(EXEEXT)
- $(OSX_ONLY) $(RM) checkers.app/Contents/MacOS/checkers$(EXEEXT)
- $(OSX_ONLY) $(RM) sudoku.app/Contents/MacOS/sudoku$(EXEEXT)
install: all
echo "Installing example programs to $(DESTDIR)$(docdir)/examples..."
@@ -288,7 +259,6 @@ install-osx:
$(INSTALL_DIR) $(DESTDIR)/Applications/$$game.app/Contents/Resources; \
fi; \
$(INSTALL_DATA) $$game.app/Contents/Info.plist $(DESTDIR)/Applications/$$game.app/Contents; \
- $(INSTALL_DATA) $$game.app/Contents/PkgInfo $(DESTDIR)/Applications/$$game.app/Contents; \
$(INSTALL_BIN) $$game.app/Contents/MacOS/$$game $(DESTDIR)/Applications/$$game.app/Contents/MacOS; \
$(INSTALL_DATA) $$game.app/Contents/Resources/$$game.icns $(DESTDIR)/Applications/$$game.app/Contents/Resources; \
done
@@ -348,16 +318,21 @@ buttons$(EXEEXT): buttons.o
blocks$(EXEEXT): blocks.o
echo Linking $@...
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) $(LDFLAGS) blocks.o -o $@ $(AUDIOLIBS) $(LINKFLTK) $(LDLIBS)
- $(OSX_ONLY) $(RM) -f -r blocks.app/Contents/MacOS
- $(OSX_ONLY) mkdir blocks.app/Contents/MacOS
+ $(OSX_ONLY) $(RM) -f -r blocks.app
+ $(OSX_ONLY) mkdir -p blocks.app/Contents/MacOS blocks.app/Contents/Resources
$(OSX_ONLY) $(INSTALL_BIN) blocks$(EXEEXT) blocks.app/Contents/MacOS
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/blocks.icns blocks.app/Contents/Resources/
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/blocks.plist blocks.app/Contents/Info.plist
checkers$(EXEEXT): checkers.o checkers_pieces.o
echo Linking $@...
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) $(LDFLAGS) checkers.o checkers_pieces.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
- $(OSX_ONLY) $(RM) -f -r checkers.app/Contents/MacOS
- $(OSX_ONLY) mkdir checkers.app/Contents/MacOS
+ $(OSX_ONLY) $(RM) -f -r checkers.app
+ $(OSX_ONLY) mkdir -p checkers.app/Contents/MacOS checkers.app/Contents/Resources
$(OSX_ONLY) $(INSTALL_BIN) checkers$(EXEEXT) checkers.app/Contents/MacOS
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/checkers.icns checkers.app/Contents/Resources/
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/checkers.plist checkers.app/Contents/Info.plist
+
checkers.cxx: checkers_pieces.h
checkers_pieces.o: checkers_pieces.h
checkers_pieces.h: checkers_pieces.fl
@@ -396,7 +371,7 @@ editor$(EXEEXT): editor.o
echo Linking $@...
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) $(LDFLAGS) editor.o -o $@ $(LINKFLTKIMG) $(LDLIBS)
$(OSX_ONLY) ../fltk-config --post $@
- $(OSX_ONLY) cp -f editor-Info.plist editor.app/Contents/Info.plist
+ $(OSX_ONLY) cp -f mac-resources/editor.plist editor.app/Contents/Info.plist
fast_slow$(EXEEXT): fast_slow.o
fast_slow.cxx: fast_slow.fl ../fluid/fluid$(EXEEXT)
@@ -548,9 +523,11 @@ subwindow$(EXEEXT): subwindow.o
sudoku: sudoku.o
echo Linking $@...
$(CXX) $(ARCHFLAGS) $(CXXFLAGS) $(LDFLAGS) sudoku.o -o $@ $(AUDIOLIBS) $(LINKFLTKIMG) $(LDLIBS)
- $(OSX_ONLY) $(RM) -r -f sudoku.app/Contents/MacOS
- $(OSX_ONLY) mkdir sudoku.app/Contents/MacOS
+ $(OSX_ONLY) $(RM) -f -r sudoku.app
+ $(OSX_ONLY) mkdir -p sudoku.app/Contents/MacOS sudoku.app/Contents/Resources
$(OSX_ONLY) $(INSTALL_BIN) sudoku$(EXEEXT) sudoku.app/Contents/MacOS
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/sudoku.icns sudoku.app/Contents/Resources/
+ $(OSX_ONLY) $(INSTALL_BIN) mac-resources/sudoku.plist sudoku.app/Contents/Info.plist
sudoku.exe: sudoku.o sudoku.rc
echo Linking $@...
diff --git a/test/blocks.app/Contents/PkgInfo b/test/blocks.app/Contents/PkgInfo
deleted file mode 100644
index 103810afb..000000000
--- a/test/blocks.app/Contents/PkgInfo
+++ /dev/null
@@ -1 +0,0 @@
-BLKSBlks
diff --git a/test/checkers.app/Contents/PkgInfo b/test/checkers.app/Contents/PkgInfo
deleted file mode 100644
index 5af7226a1..000000000
--- a/test/checkers.app/Contents/PkgInfo
+++ /dev/null
@@ -1 +0,0 @@
-FLSUFlsu
diff --git a/test/blocks.app/Contents/Resources/blocks.icns b/test/mac-resources/blocks.icns
index 7e7ba24eb..7e7ba24eb 100644
--- a/test/blocks.app/Contents/Resources/blocks.icns
+++ b/test/mac-resources/blocks.icns
Binary files differ
diff --git a/test/blocks.app/Contents/Info.plist b/test/mac-resources/blocks.plist
index 9448901b6..bb256be62 100644
--- a/test/blocks.app/Contents/Info.plist
+++ b/test/mac-resources/blocks.plist
@@ -8,7 +8,7 @@
<string>blocks</string>
<key>CFBundleIdentifier</key>
- <string>com.easysw.blocks</string>
+ <string>org.fltk.blocks</string>
<key>CFBundleVersion</key>
<string>1.0</string>
@@ -17,7 +17,7 @@
<string>English</string>
<key>NSHumanReadableCopyright</key>
- <string>Copyright 2006 by Michael Sweet</string>
+ <string>Copyright 2006-2021 by Michael Sweet</string>
<key>CFAppleHelpAnchor</key>
<string>help</string>
@@ -38,7 +38,7 @@
<string>1.0</string>
<key>CFBundleGetInfoString</key>
- <string>1.0, Copyright 2006 by Michael Sweet</string>
+ <string>1.0, Copyright 2006-2021 by Michael Sweet</string>
<key>NSHighResolutionCapable</key>
<true/>
diff --git a/test/checkers.app/Contents/Resources/checkers.icns b/test/mac-resources/checkers.icns
index 5bdec121c..5bdec121c 100644
--- a/test/checkers.app/Contents/Resources/checkers.icns
+++ b/test/mac-resources/checkers.icns
Binary files differ
diff --git a/test/checkers.app/Contents/Info.plist b/test/mac-resources/checkers.plist
index 4929602ca..66ec8d1e9 100644
--- a/test/checkers.app/Contents/Info.plist
+++ b/test/mac-resources/checkers.plist
@@ -17,7 +17,7 @@
<string>English</string>
<key>NSHumanReadableCopyright</key>
- <string>Copyright 1997-2010 by Bill Spitzak and others</string>
+ <string>Copyright 1997-2021 by Bill Spitzak and others</string>
<key>CFAppleHelpAnchor</key>
<string>help</string>
@@ -29,7 +29,7 @@
<string>APPL</string>
<key>CFBundleSignature</key>
- <string>FLSU</string>
+ <string>FLCK</string>
<key>CFBundleIconFile</key>
<string>checkers.icns</string>
@@ -38,7 +38,7 @@
<string>1.0</string>
<key>CFBundleGetInfoString</key>
- <string>1.0, Copyright 1997-2010 by Bill Spitzak and others</string>
+ <string>1.0, Copyright 1997-2021 by Bill Spitzak and others</string>
<key>NSHighResolutionCapable</key>
<true/>
diff --git a/test/editor-Info.plist b/test/mac-resources/editor.plist
index dea3f13f5..6324e5cf2 100644
--- a/test/editor-Info.plist
+++ b/test/mac-resources/editor.plist
@@ -36,7 +36,7 @@
<key>CFBundleVersion</key>
<string>1.0</string>
<key>NSHumanReadableCopyright</key>
- <string>Copyright 1998-2010 by Bill Spitzak and others.</string>
+ <string>Copyright 1998-2021 by Bill Spitzak and others.</string>
<key>NSHighResolutionCapable</key>
<true/>
</dict>
diff --git a/test/sudoku.app/Contents/Resources/sudoku.icns b/test/mac-resources/sudoku.icns
index abbe75ef0..abbe75ef0 100644
--- a/test/sudoku.app/Contents/Resources/sudoku.icns
+++ b/test/mac-resources/sudoku.icns
Binary files differ
diff --git a/test/sudoku.app/Contents/Info.plist b/test/mac-resources/sudoku.plist
index b75285c37..058382811 100644
--- a/test/sudoku.app/Contents/Info.plist
+++ b/test/mac-resources/sudoku.plist
@@ -17,7 +17,7 @@
<string>English</string>
<key>NSHumanReadableCopyright</key>
- <string>Copyright 2005-2006 by Michael Sweet</string>
+ <string>Copyright 2005-2021 by Michael Sweet</string>
<key>CFAppleHelpAnchor</key>
<string>help</string>
@@ -38,7 +38,7 @@
<string>1.0</string>
<key>CFBundleGetInfoString</key>
- <string>1.0, Copyright 2005-2006 by Michael Sweet</string>
+ <string>1.0, Copyright 2005-2021 by Michael Sweet</string>
<key>NSHighResolutionCapable</key>
<true/>
diff --git a/test/sudoku.app/Contents/PkgInfo b/test/sudoku.app/Contents/PkgInfo
deleted file mode 100644
index 5af7226a1..000000000
--- a/test/sudoku.app/Contents/PkgInfo
+++ /dev/null
@@ -1 +0,0 @@
-FLSUFlsu