filedialog 0.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (79) hide show
  1. checksums.yaml +7 -0
  2. data/.github/workflows/gempush.yml +31 -0
  3. data/.gitignore +13 -0
  4. data/.gitmodules +3 -0
  5. data/.rubocop.yml +19 -0
  6. data/Gemfile +10 -0
  7. data/Gemfile.lock +30 -0
  8. data/LICENSE +674 -0
  9. data/README.md +22 -0
  10. data/Rakefile +35 -0
  11. data/bin/console +25 -0
  12. data/deps/filedialogbuilddeps.rb +49 -0
  13. data/deps/nativefiledialog/.github/ISSUE_TEMPLATE/bug_report.md +32 -0
  14. data/deps/nativefiledialog/.gitignore +181 -0
  15. data/deps/nativefiledialog/LICENSE +16 -0
  16. data/deps/nativefiledialog/README.md +180 -0
  17. data/deps/nativefiledialog/build/dont_run_premake.txt +1 -0
  18. data/deps/nativefiledialog/build/gmake_linux/Makefile +101 -0
  19. data/deps/nativefiledialog/build/gmake_linux/nfd.make +192 -0
  20. data/deps/nativefiledialog/build/gmake_linux/test_opendialog.make +188 -0
  21. data/deps/nativefiledialog/build/gmake_linux/test_opendialogmultiple.make +188 -0
  22. data/deps/nativefiledialog/build/gmake_linux/test_pickfolder.make +188 -0
  23. data/deps/nativefiledialog/build/gmake_linux/test_savedialog.make +188 -0
  24. data/deps/nativefiledialog/build/gmake_linux_zenity/Makefile +101 -0
  25. data/deps/nativefiledialog/build/gmake_linux_zenity/nfd.make +192 -0
  26. data/deps/nativefiledialog/build/gmake_linux_zenity/test_opendialog.make +188 -0
  27. data/deps/nativefiledialog/build/gmake_linux_zenity/test_opendialogmultiple.make +188 -0
  28. data/deps/nativefiledialog/build/gmake_linux_zenity/test_pickfolder.make +188 -0
  29. data/deps/nativefiledialog/build/gmake_linux_zenity/test_savedialog.make +188 -0
  30. data/deps/nativefiledialog/build/gmake_macosx/Makefile +85 -0
  31. data/deps/nativefiledialog/build/gmake_macosx/nfd.make +154 -0
  32. data/deps/nativefiledialog/build/gmake_macosx/test_opendialog.make +150 -0
  33. data/deps/nativefiledialog/build/gmake_macosx/test_opendialogmultiple.make +150 -0
  34. data/deps/nativefiledialog/build/gmake_macosx/test_pickfolder.make +150 -0
  35. data/deps/nativefiledialog/build/gmake_macosx/test_savedialog.make +150 -0
  36. data/deps/nativefiledialog/build/gmake_windows/Makefile +101 -0
  37. data/deps/nativefiledialog/build/gmake_windows/nfd.make +192 -0
  38. data/deps/nativefiledialog/build/gmake_windows/test_opendialog.make +188 -0
  39. data/deps/nativefiledialog/build/gmake_windows/test_opendialogmultiple.make +188 -0
  40. data/deps/nativefiledialog/build/gmake_windows/test_pickfolder.make +188 -0
  41. data/deps/nativefiledialog/build/gmake_windows/test_savedialog.make +188 -0
  42. data/deps/nativefiledialog/build/premake5.lua +265 -0
  43. data/deps/nativefiledialog/build/vs2010/NativeFileDialog.sln +78 -0
  44. data/deps/nativefiledialog/build/vs2010/nfd.vcxproj +168 -0
  45. data/deps/nativefiledialog/build/vs2010/nfd.vcxproj.filters +20 -0
  46. data/deps/nativefiledialog/build/vs2010/test_opendialog.vcxproj +182 -0
  47. data/deps/nativefiledialog/build/vs2010/test_opendialogmultiple.vcxproj +182 -0
  48. data/deps/nativefiledialog/build/vs2010/test_pickfolder.vcxproj +182 -0
  49. data/deps/nativefiledialog/build/vs2010/test_savedialog.vcxproj +182 -0
  50. data/deps/nativefiledialog/build/xcode4/NativeFileDialog.xcworkspace/contents.xcworkspacedata +19 -0
  51. data/deps/nativefiledialog/build/xcode4/nfd.xcodeproj/project.pbxproj +228 -0
  52. data/deps/nativefiledialog/build/xcode4/test_opendialog.xcodeproj/project.pbxproj +294 -0
  53. data/deps/nativefiledialog/build/xcode4/test_opendialogmultiple.xcodeproj/project.pbxproj +294 -0
  54. data/deps/nativefiledialog/build/xcode4/test_pickfolder.xcodeproj/project.pbxproj +294 -0
  55. data/deps/nativefiledialog/build/xcode4/test_savedialog.xcodeproj/project.pbxproj +294 -0
  56. data/deps/nativefiledialog/docs/build.md +39 -0
  57. data/deps/nativefiledialog/docs/contributing.md +25 -0
  58. data/deps/nativefiledialog/screens/open_cocoa.png +0 -0
  59. data/deps/nativefiledialog/screens/open_gtk3.png +0 -0
  60. data/deps/nativefiledialog/screens/open_win.png +0 -0
  61. data/deps/nativefiledialog/src/common.h +21 -0
  62. data/deps/nativefiledialog/src/include/nfd.h +74 -0
  63. data/deps/nativefiledialog/src/nfd_cocoa.m +286 -0
  64. data/deps/nativefiledialog/src/nfd_common.c +142 -0
  65. data/deps/nativefiledialog/src/nfd_common.h +39 -0
  66. data/deps/nativefiledialog/src/nfd_gtk.c +379 -0
  67. data/deps/nativefiledialog/src/nfd_win.cpp +762 -0
  68. data/deps/nativefiledialog/src/nfd_zenity.c +307 -0
  69. data/deps/nativefiledialog/src/simple_exec.h +218 -0
  70. data/deps/nativefiledialog/test/test_opendialog.c +29 -0
  71. data/deps/nativefiledialog/test/test_opendialogmultiple.c +32 -0
  72. data/deps/nativefiledialog/test/test_pickfolder.c +29 -0
  73. data/deps/nativefiledialog/test/test_savedialog.c +28 -0
  74. data/ext/filedialog/extconf.rb +58 -0
  75. data/ext/filedialog/filedialog.c +118 -0
  76. data/filedialog.gemspec +48 -0
  77. data/lib/filedialog.rb +50 -0
  78. data/lib/filedialog/version.rb +5 -0
  79. metadata +137 -0
@@ -0,0 +1,85 @@
1
+ # GNU Make workspace makefile autogenerated by Premake
2
+
3
+ ifndef config
4
+ config=release_x64
5
+ endif
6
+
7
+ ifndef verbose
8
+ SILENT = @
9
+ endif
10
+
11
+ ifeq ($(config),release_x64)
12
+ nfd_config = release_x64
13
+ test_pickfolder_config = release_x64
14
+ test_opendialog_config = release_x64
15
+ test_opendialogmultiple_config = release_x64
16
+ test_savedialog_config = release_x64
17
+ endif
18
+ ifeq ($(config),debug_x64)
19
+ nfd_config = debug_x64
20
+ test_pickfolder_config = debug_x64
21
+ test_opendialog_config = debug_x64
22
+ test_opendialogmultiple_config = debug_x64
23
+ test_savedialog_config = debug_x64
24
+ endif
25
+
26
+ PROJECTS := nfd test_pickfolder test_opendialog test_opendialogmultiple test_savedialog
27
+
28
+ .PHONY: all clean help $(PROJECTS)
29
+
30
+ all: $(PROJECTS)
31
+
32
+ nfd:
33
+ ifneq (,$(nfd_config))
34
+ @echo "==== Building nfd ($(nfd_config)) ===="
35
+ @${MAKE} --no-print-directory -C . -f nfd.make config=$(nfd_config)
36
+ endif
37
+
38
+ test_pickfolder: nfd
39
+ ifneq (,$(test_pickfolder_config))
40
+ @echo "==== Building test_pickfolder ($(test_pickfolder_config)) ===="
41
+ @${MAKE} --no-print-directory -C . -f test_pickfolder.make config=$(test_pickfolder_config)
42
+ endif
43
+
44
+ test_opendialog: nfd
45
+ ifneq (,$(test_opendialog_config))
46
+ @echo "==== Building test_opendialog ($(test_opendialog_config)) ===="
47
+ @${MAKE} --no-print-directory -C . -f test_opendialog.make config=$(test_opendialog_config)
48
+ endif
49
+
50
+ test_opendialogmultiple: nfd
51
+ ifneq (,$(test_opendialogmultiple_config))
52
+ @echo "==== Building test_opendialogmultiple ($(test_opendialogmultiple_config)) ===="
53
+ @${MAKE} --no-print-directory -C . -f test_opendialogmultiple.make config=$(test_opendialogmultiple_config)
54
+ endif
55
+
56
+ test_savedialog: nfd
57
+ ifneq (,$(test_savedialog_config))
58
+ @echo "==== Building test_savedialog ($(test_savedialog_config)) ===="
59
+ @${MAKE} --no-print-directory -C . -f test_savedialog.make config=$(test_savedialog_config)
60
+ endif
61
+
62
+ clean:
63
+ @${MAKE} --no-print-directory -C . -f nfd.make clean
64
+ @${MAKE} --no-print-directory -C . -f test_pickfolder.make clean
65
+ @${MAKE} --no-print-directory -C . -f test_opendialog.make clean
66
+ @${MAKE} --no-print-directory -C . -f test_opendialogmultiple.make clean
67
+ @${MAKE} --no-print-directory -C . -f test_savedialog.make clean
68
+
69
+ help:
70
+ @echo "Usage: make [config=name] [target]"
71
+ @echo ""
72
+ @echo "CONFIGURATIONS:"
73
+ @echo " release_x64"
74
+ @echo " debug_x64"
75
+ @echo ""
76
+ @echo "TARGETS:"
77
+ @echo " all (default)"
78
+ @echo " clean"
79
+ @echo " nfd"
80
+ @echo " test_pickfolder"
81
+ @echo " test_opendialog"
82
+ @echo " test_opendialogmultiple"
83
+ @echo " test_savedialog"
84
+ @echo ""
85
+ @echo "For more information, see https://github.com/premake/premake-core/wiki"
@@ -0,0 +1,154 @@
1
+ # GNU Make project makefile autogenerated by Premake
2
+
3
+ ifndef config
4
+ config=release_x64
5
+ endif
6
+
7
+ ifndef verbose
8
+ SILENT = @
9
+ endif
10
+
11
+ .PHONY: clean prebuild prelink
12
+
13
+ ifeq ($(config),release_x64)
14
+ ifeq ($(origin CC), default)
15
+ CC = clang
16
+ endif
17
+ ifeq ($(origin CXX), default)
18
+ CXX = clang++
19
+ endif
20
+ ifeq ($(origin AR), default)
21
+ AR = ar
22
+ endif
23
+ TARGETDIR = ../lib/Release/x64
24
+ TARGET = $(TARGETDIR)/libnfd.a
25
+ OBJDIR = obj/x64/Release/nfd
26
+ DEFINES += -DNDEBUG
27
+ INCLUDES += -I../../src/include
28
+ FORCE_INCLUDE +=
29
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
30
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -O2 -Wall -Wextra -fno-exceptions
31
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -O2 -Wall -Wextra -fno-exceptions
32
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
33
+ LIBS +=
34
+ LDDEPS +=
35
+ ALL_LDFLAGS += $(LDFLAGS) -m64
36
+ LINKCMD = $(AR) -rcs "$@" $(OBJECTS)
37
+ define PREBUILDCMDS
38
+ endef
39
+ define PRELINKCMDS
40
+ endef
41
+ define POSTBUILDCMDS
42
+ endef
43
+ all: prebuild prelink $(TARGET)
44
+ @:
45
+
46
+ endif
47
+
48
+ ifeq ($(config),debug_x64)
49
+ ifeq ($(origin CC), default)
50
+ CC = clang
51
+ endif
52
+ ifeq ($(origin CXX), default)
53
+ CXX = clang++
54
+ endif
55
+ ifeq ($(origin AR), default)
56
+ AR = ar
57
+ endif
58
+ TARGETDIR = ../lib/Debug/x64
59
+ TARGET = $(TARGETDIR)/libnfd_d.a
60
+ OBJDIR = obj/x64/Debug/nfd
61
+ DEFINES += -DDEBUG
62
+ INCLUDES += -I../../src/include
63
+ FORCE_INCLUDE +=
64
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
65
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -g -Wall -Wextra -fno-exceptions
66
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -g -Wall -Wextra -fno-exceptions
67
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
68
+ LIBS +=
69
+ LDDEPS +=
70
+ ALL_LDFLAGS += $(LDFLAGS) -m64
71
+ LINKCMD = $(AR) -rcs "$@" $(OBJECTS)
72
+ define PREBUILDCMDS
73
+ endef
74
+ define PRELINKCMDS
75
+ endef
76
+ define POSTBUILDCMDS
77
+ endef
78
+ all: prebuild prelink $(TARGET)
79
+ @:
80
+
81
+ endif
82
+
83
+ OBJECTS := \
84
+ $(OBJDIR)/nfd_cocoa.o \
85
+ $(OBJDIR)/nfd_common.o \
86
+
87
+ RESOURCES := \
88
+
89
+ CUSTOMFILES := \
90
+
91
+ SHELLTYPE := posix
92
+ ifeq (.exe,$(findstring .exe,$(ComSpec)))
93
+ SHELLTYPE := msdos
94
+ endif
95
+
96
+ $(TARGET): $(GCH) ${CUSTOMFILES} $(OBJECTS) $(LDDEPS) $(RESOURCES) | $(TARGETDIR)
97
+ @echo Linking nfd
98
+ $(SILENT) $(LINKCMD)
99
+ $(POSTBUILDCMDS)
100
+
101
+ $(CUSTOMFILES): | $(OBJDIR)
102
+
103
+ $(TARGETDIR):
104
+ @echo Creating $(TARGETDIR)
105
+ ifeq (posix,$(SHELLTYPE))
106
+ $(SILENT) mkdir -p $(TARGETDIR)
107
+ else
108
+ $(SILENT) mkdir $(subst /,\\,$(TARGETDIR))
109
+ endif
110
+
111
+ $(OBJDIR):
112
+ @echo Creating $(OBJDIR)
113
+ ifeq (posix,$(SHELLTYPE))
114
+ $(SILENT) mkdir -p $(OBJDIR)
115
+ else
116
+ $(SILENT) mkdir $(subst /,\\,$(OBJDIR))
117
+ endif
118
+
119
+ clean:
120
+ @echo Cleaning nfd
121
+ ifeq (posix,$(SHELLTYPE))
122
+ $(SILENT) rm -f $(TARGET)
123
+ $(SILENT) rm -rf $(OBJDIR)
124
+ else
125
+ $(SILENT) if exist $(subst /,\\,$(TARGET)) del $(subst /,\\,$(TARGET))
126
+ $(SILENT) if exist $(subst /,\\,$(OBJDIR)) rmdir /s /q $(subst /,\\,$(OBJDIR))
127
+ endif
128
+
129
+ prebuild:
130
+ $(PREBUILDCMDS)
131
+
132
+ prelink:
133
+ $(PRELINKCMDS)
134
+
135
+ ifneq (,$(PCH))
136
+ $(OBJECTS): $(GCH) $(PCH) | $(OBJDIR)
137
+ $(GCH): $(PCH) | $(OBJDIR)
138
+ @echo $(notdir $<)
139
+ $(SILENT) $(CC) -x c-header $(ALL_CFLAGS) -o "$@" -MF "$(@:%.gch=%.d)" -c "$<"
140
+ else
141
+ $(OBJECTS): | $(OBJDIR)
142
+ endif
143
+
144
+ $(OBJDIR)/nfd_cocoa.o: ../../src/nfd_cocoa.m
145
+ @echo $(notdir $<)
146
+ $(SILENT) $(CC) $(ALL_CFLAGS) $(FORCE_INCLUDE) -o "$@" -MF "$(@:%.o=%.d)" -c "$<"
147
+ $(OBJDIR)/nfd_common.o: ../../src/nfd_common.c
148
+ @echo $(notdir $<)
149
+ $(SILENT) $(CC) $(ALL_CFLAGS) $(FORCE_INCLUDE) -o "$@" -MF "$(@:%.o=%.d)" -c "$<"
150
+
151
+ -include $(OBJECTS:%.o=%.d)
152
+ ifneq (,$(PCH))
153
+ -include $(OBJDIR)/$(notdir $(PCH)).d
154
+ endif
@@ -0,0 +1,150 @@
1
+ # GNU Make project makefile autogenerated by Premake
2
+
3
+ ifndef config
4
+ config=release_x64
5
+ endif
6
+
7
+ ifndef verbose
8
+ SILENT = @
9
+ endif
10
+
11
+ .PHONY: clean prebuild prelink
12
+
13
+ ifeq ($(config),release_x64)
14
+ ifeq ($(origin CC), default)
15
+ CC = clang
16
+ endif
17
+ ifeq ($(origin CXX), default)
18
+ CXX = clang++
19
+ endif
20
+ ifeq ($(origin AR), default)
21
+ AR = ar
22
+ endif
23
+ TARGETDIR = ../bin
24
+ TARGET = $(TARGETDIR)/test_opendialog
25
+ OBJDIR = obj/x64/Release/test_opendialog
26
+ DEFINES += -DNDEBUG
27
+ INCLUDES += -I../../src/include
28
+ FORCE_INCLUDE +=
29
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
30
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -O2
31
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -O2
32
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
33
+ LIBS += ../lib/Release/x64/libnfd.a -framework Foundation -framework AppKit
34
+ LDDEPS += ../lib/Release/x64/libnfd.a
35
+ ALL_LDFLAGS += $(LDFLAGS) -L../lib/Release/x64 -m64
36
+ LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
37
+ define PREBUILDCMDS
38
+ endef
39
+ define PRELINKCMDS
40
+ endef
41
+ define POSTBUILDCMDS
42
+ endef
43
+ all: prebuild prelink $(TARGET)
44
+ @:
45
+
46
+ endif
47
+
48
+ ifeq ($(config),debug_x64)
49
+ ifeq ($(origin CC), default)
50
+ CC = clang
51
+ endif
52
+ ifeq ($(origin CXX), default)
53
+ CXX = clang++
54
+ endif
55
+ ifeq ($(origin AR), default)
56
+ AR = ar
57
+ endif
58
+ TARGETDIR = ../bin
59
+ TARGET = $(TARGETDIR)/test_opendialog_d
60
+ OBJDIR = obj/x64/Debug/test_opendialog
61
+ DEFINES += -DDEBUG
62
+ INCLUDES += -I../../src/include
63
+ FORCE_INCLUDE +=
64
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
65
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -g
66
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -g
67
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
68
+ LIBS += -framework Foundation -framework AppKit -lnfd_d
69
+ LDDEPS +=
70
+ ALL_LDFLAGS += $(LDFLAGS) -L../lib/Debug/x64 -m64
71
+ LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
72
+ define PREBUILDCMDS
73
+ endef
74
+ define PRELINKCMDS
75
+ endef
76
+ define POSTBUILDCMDS
77
+ endef
78
+ all: prebuild prelink $(TARGET)
79
+ @:
80
+
81
+ endif
82
+
83
+ OBJECTS := \
84
+ $(OBJDIR)/test_opendialog.o \
85
+
86
+ RESOURCES := \
87
+
88
+ CUSTOMFILES := \
89
+
90
+ SHELLTYPE := posix
91
+ ifeq (.exe,$(findstring .exe,$(ComSpec)))
92
+ SHELLTYPE := msdos
93
+ endif
94
+
95
+ $(TARGET): $(GCH) ${CUSTOMFILES} $(OBJECTS) $(LDDEPS) $(RESOURCES) | $(TARGETDIR)
96
+ @echo Linking test_opendialog
97
+ $(SILENT) $(LINKCMD)
98
+ $(POSTBUILDCMDS)
99
+
100
+ $(CUSTOMFILES): | $(OBJDIR)
101
+
102
+ $(TARGETDIR):
103
+ @echo Creating $(TARGETDIR)
104
+ ifeq (posix,$(SHELLTYPE))
105
+ $(SILENT) mkdir -p $(TARGETDIR)
106
+ else
107
+ $(SILENT) mkdir $(subst /,\\,$(TARGETDIR))
108
+ endif
109
+
110
+ $(OBJDIR):
111
+ @echo Creating $(OBJDIR)
112
+ ifeq (posix,$(SHELLTYPE))
113
+ $(SILENT) mkdir -p $(OBJDIR)
114
+ else
115
+ $(SILENT) mkdir $(subst /,\\,$(OBJDIR))
116
+ endif
117
+
118
+ clean:
119
+ @echo Cleaning test_opendialog
120
+ ifeq (posix,$(SHELLTYPE))
121
+ $(SILENT) rm -f $(TARGET)
122
+ $(SILENT) rm -rf $(OBJDIR)
123
+ else
124
+ $(SILENT) if exist $(subst /,\\,$(TARGET)) del $(subst /,\\,$(TARGET))
125
+ $(SILENT) if exist $(subst /,\\,$(OBJDIR)) rmdir /s /q $(subst /,\\,$(OBJDIR))
126
+ endif
127
+
128
+ prebuild:
129
+ $(PREBUILDCMDS)
130
+
131
+ prelink:
132
+ $(PRELINKCMDS)
133
+
134
+ ifneq (,$(PCH))
135
+ $(OBJECTS): $(GCH) $(PCH) | $(OBJDIR)
136
+ $(GCH): $(PCH) | $(OBJDIR)
137
+ @echo $(notdir $<)
138
+ $(SILENT) $(CC) -x c-header $(ALL_CFLAGS) -o "$@" -MF "$(@:%.gch=%.d)" -c "$<"
139
+ else
140
+ $(OBJECTS): | $(OBJDIR)
141
+ endif
142
+
143
+ $(OBJDIR)/test_opendialog.o: ../../test/test_opendialog.c
144
+ @echo $(notdir $<)
145
+ $(SILENT) $(CC) $(ALL_CFLAGS) $(FORCE_INCLUDE) -o "$@" -MF "$(@:%.o=%.d)" -c "$<"
146
+
147
+ -include $(OBJECTS:%.o=%.d)
148
+ ifneq (,$(PCH))
149
+ -include $(OBJDIR)/$(notdir $(PCH)).d
150
+ endif
@@ -0,0 +1,150 @@
1
+ # GNU Make project makefile autogenerated by Premake
2
+
3
+ ifndef config
4
+ config=release_x64
5
+ endif
6
+
7
+ ifndef verbose
8
+ SILENT = @
9
+ endif
10
+
11
+ .PHONY: clean prebuild prelink
12
+
13
+ ifeq ($(config),release_x64)
14
+ ifeq ($(origin CC), default)
15
+ CC = clang
16
+ endif
17
+ ifeq ($(origin CXX), default)
18
+ CXX = clang++
19
+ endif
20
+ ifeq ($(origin AR), default)
21
+ AR = ar
22
+ endif
23
+ TARGETDIR = ../bin
24
+ TARGET = $(TARGETDIR)/test_opendialogmultiple
25
+ OBJDIR = obj/x64/Release/test_opendialogmultiple
26
+ DEFINES += -DNDEBUG
27
+ INCLUDES += -I../../src/include
28
+ FORCE_INCLUDE +=
29
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
30
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -O2
31
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -O2
32
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
33
+ LIBS += ../lib/Release/x64/libnfd.a -framework Foundation -framework AppKit
34
+ LDDEPS += ../lib/Release/x64/libnfd.a
35
+ ALL_LDFLAGS += $(LDFLAGS) -L../lib/Release/x64 -m64
36
+ LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
37
+ define PREBUILDCMDS
38
+ endef
39
+ define PRELINKCMDS
40
+ endef
41
+ define POSTBUILDCMDS
42
+ endef
43
+ all: prebuild prelink $(TARGET)
44
+ @:
45
+
46
+ endif
47
+
48
+ ifeq ($(config),debug_x64)
49
+ ifeq ($(origin CC), default)
50
+ CC = clang
51
+ endif
52
+ ifeq ($(origin CXX), default)
53
+ CXX = clang++
54
+ endif
55
+ ifeq ($(origin AR), default)
56
+ AR = ar
57
+ endif
58
+ TARGETDIR = ../bin
59
+ TARGET = $(TARGETDIR)/test_opendialogmultiple_d
60
+ OBJDIR = obj/x64/Debug/test_opendialogmultiple
61
+ DEFINES += -DDEBUG
62
+ INCLUDES += -I../../src/include
63
+ FORCE_INCLUDE +=
64
+ ALL_CPPFLAGS += $(CPPFLAGS) -MMD -MP $(DEFINES) $(INCLUDES)
65
+ ALL_CFLAGS += $(CFLAGS) $(ALL_CPPFLAGS) -m64 -g
66
+ ALL_CXXFLAGS += $(CXXFLAGS) $(ALL_CPPFLAGS) -m64 -g
67
+ ALL_RESFLAGS += $(RESFLAGS) $(DEFINES) $(INCLUDES)
68
+ LIBS += -framework Foundation -framework AppKit -lnfd_d
69
+ LDDEPS +=
70
+ ALL_LDFLAGS += $(LDFLAGS) -L../lib/Debug/x64 -m64
71
+ LINKCMD = $(CC) -o "$@" $(OBJECTS) $(RESOURCES) $(ALL_LDFLAGS) $(LIBS)
72
+ define PREBUILDCMDS
73
+ endef
74
+ define PRELINKCMDS
75
+ endef
76
+ define POSTBUILDCMDS
77
+ endef
78
+ all: prebuild prelink $(TARGET)
79
+ @:
80
+
81
+ endif
82
+
83
+ OBJECTS := \
84
+ $(OBJDIR)/test_opendialogmultiple.o \
85
+
86
+ RESOURCES := \
87
+
88
+ CUSTOMFILES := \
89
+
90
+ SHELLTYPE := posix
91
+ ifeq (.exe,$(findstring .exe,$(ComSpec)))
92
+ SHELLTYPE := msdos
93
+ endif
94
+
95
+ $(TARGET): $(GCH) ${CUSTOMFILES} $(OBJECTS) $(LDDEPS) $(RESOURCES) | $(TARGETDIR)
96
+ @echo Linking test_opendialogmultiple
97
+ $(SILENT) $(LINKCMD)
98
+ $(POSTBUILDCMDS)
99
+
100
+ $(CUSTOMFILES): | $(OBJDIR)
101
+
102
+ $(TARGETDIR):
103
+ @echo Creating $(TARGETDIR)
104
+ ifeq (posix,$(SHELLTYPE))
105
+ $(SILENT) mkdir -p $(TARGETDIR)
106
+ else
107
+ $(SILENT) mkdir $(subst /,\\,$(TARGETDIR))
108
+ endif
109
+
110
+ $(OBJDIR):
111
+ @echo Creating $(OBJDIR)
112
+ ifeq (posix,$(SHELLTYPE))
113
+ $(SILENT) mkdir -p $(OBJDIR)
114
+ else
115
+ $(SILENT) mkdir $(subst /,\\,$(OBJDIR))
116
+ endif
117
+
118
+ clean:
119
+ @echo Cleaning test_opendialogmultiple
120
+ ifeq (posix,$(SHELLTYPE))
121
+ $(SILENT) rm -f $(TARGET)
122
+ $(SILENT) rm -rf $(OBJDIR)
123
+ else
124
+ $(SILENT) if exist $(subst /,\\,$(TARGET)) del $(subst /,\\,$(TARGET))
125
+ $(SILENT) if exist $(subst /,\\,$(OBJDIR)) rmdir /s /q $(subst /,\\,$(OBJDIR))
126
+ endif
127
+
128
+ prebuild:
129
+ $(PREBUILDCMDS)
130
+
131
+ prelink:
132
+ $(PRELINKCMDS)
133
+
134
+ ifneq (,$(PCH))
135
+ $(OBJECTS): $(GCH) $(PCH) | $(OBJDIR)
136
+ $(GCH): $(PCH) | $(OBJDIR)
137
+ @echo $(notdir $<)
138
+ $(SILENT) $(CC) -x c-header $(ALL_CFLAGS) -o "$@" -MF "$(@:%.gch=%.d)" -c "$<"
139
+ else
140
+ $(OBJECTS): | $(OBJDIR)
141
+ endif
142
+
143
+ $(OBJDIR)/test_opendialogmultiple.o: ../../test/test_opendialogmultiple.c
144
+ @echo $(notdir $<)
145
+ $(SILENT) $(CC) $(ALL_CFLAGS) $(FORCE_INCLUDE) -o "$@" -MF "$(@:%.o=%.d)" -c "$<"
146
+
147
+ -include $(OBJECTS:%.o=%.d)
148
+ ifneq (,$(PCH))
149
+ -include $(OBJDIR)/$(notdir $(PCH)).d
150
+ endif