rb-scpt 1.0.2 → 1.0.3

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 470ba8dfaf4bbe261d30036cd5fa9bd5788f2a9d
4
- data.tar.gz: 30eb7123f32488069a4436957bac32d3526d4578
2
+ SHA256:
3
+ metadata.gz: a608f6dc1d35cf6fcc4b5fd167a47577c09d8cb94b2e60b28e4583154b5d422a
4
+ data.tar.gz: f248e1a01ff3f3f13dc3e8d3e804d815c15e557fa26d7bb78601fb30e8adb89f
5
5
  SHA512:
6
- metadata.gz: c6e8dbdea21e3f3cf21574a413a6ca66f2a8190ccf6887044ad58790ce60e6a82b3e2ef0b94ea453cbd97cea516ab52fbe7067346853782ef1073ba724c6e6f6
7
- data.tar.gz: 721f9a75a460b0601e1faf0bfe0b1b76e742615f1f3ffaf4346c6e0bef36953f6fd5fcf67e9b4b4e355aa55261206b781f7362618dc8999720d3457330bc241f
6
+ metadata.gz: c2d9919603636037c41a428db960639f7d22aada5c84ddda19b4c894278b6f2d3d3933082b56eee84713607eed5e2950f8862472b6dc175fa97b6f52aceaa39c
7
+ data.tar.gz: 9c17df5bf5fa209d61e10b86e6575b30acca7bbd78fa1fc914ed9e63a913545b57ff97a70dc8128389386159e2f1bb0cc4472990ed5a68108e5cac752b2cfee7
@@ -0,0 +1,327 @@
1
+
2
+ SHELL = /bin/sh
3
+
4
+ # V=0 quiet, V=1 verbose. other values don't work.
5
+ V = 0
6
+ Q1 = $(V:1=)
7
+ Q = $(Q1:0=@)
8
+ ECHO1 = $(V:1=@ :)
9
+ ECHO = $(ECHO1:0=@ echo)
10
+ NULLCMD = :
11
+
12
+ #### Start of system configuration section. ####
13
+
14
+ srcdir = src
15
+ topdir = /usr/local/Cellar/ruby/2.4.2_1/include/ruby-2.4.0
16
+ hdrdir = $(topdir)
17
+ arch_hdrdir = /usr/local/Cellar/ruby/2.4.2_1/include/ruby-2.4.0/x86_64-darwin17
18
+ PATH_SEPARATOR = :
19
+ VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby
20
+ prefix = $(DESTDIR)/usr/local/Cellar/ruby/2.4.2_1
21
+ rubysitearchprefix = $(rubylibprefix)/$(sitearch)
22
+ rubyarchprefix = $(rubylibprefix)/$(arch)
23
+ rubylibprefix = $(libdir)/$(RUBY_BASE_NAME)
24
+ exec_prefix = $(prefix)
25
+ vendorarchhdrdir = $(vendorhdrdir)/$(sitearch)
26
+ sitearchhdrdir = $(sitehdrdir)/$(sitearch)
27
+ rubyarchhdrdir = $(rubyhdrdir)/$(arch)
28
+ vendorhdrdir = $(rubyhdrdir)/vendor_ruby
29
+ sitehdrdir = $(rubyhdrdir)/site_ruby
30
+ rubyhdrdir = $(includedir)/$(RUBY_VERSION_NAME)
31
+ vendorarchdir = $(vendorlibdir)/$(sitearch)
32
+ vendorlibdir = $(vendordir)/$(ruby_version)
33
+ vendordir = $(DESTDIR)/usr/local/lib/ruby/vendor_ruby
34
+ sitearchdir = $(sitelibdir)/$(sitearch)
35
+ sitelibdir = $(sitedir)/$(ruby_version)
36
+ sitedir = $(DESTDIR)/usr/local/lib/ruby/site_ruby
37
+ rubyarchdir = $(rubylibdir)/$(arch)
38
+ rubylibdir = $(rubylibprefix)/$(ruby_version)
39
+ sitearchincludedir = $(includedir)/$(sitearch)
40
+ archincludedir = $(includedir)/$(arch)
41
+ sitearchlibdir = $(libdir)/$(sitearch)
42
+ archlibdir = $(libdir)/$(arch)
43
+ ridir = $(datarootdir)/$(RI_BASE_NAME)
44
+ mandir = $(datarootdir)/man
45
+ localedir = $(datarootdir)/locale
46
+ libdir = $(exec_prefix)/lib
47
+ psdir = $(docdir)
48
+ pdfdir = $(docdir)
49
+ dvidir = $(docdir)
50
+ htmldir = $(docdir)
51
+ infodir = $(datarootdir)/info
52
+ docdir = $(datarootdir)/doc/$(PACKAGE)
53
+ oldincludedir = $(SDKROOT)/usr/include
54
+ includedir = $(prefix)/include
55
+ localstatedir = $(prefix)/var
56
+ sharedstatedir = $(prefix)/com
57
+ sysconfdir = $(prefix)/etc
58
+ datadir = $(datarootdir)
59
+ datarootdir = $(prefix)/share
60
+ libexecdir = $(exec_prefix)/libexec
61
+ sbindir = $(exec_prefix)/sbin
62
+ bindir = $(exec_prefix)/bin
63
+ archdir = $(rubyarchdir)
64
+
65
+
66
+ CC = clang
67
+ CXX = clang++
68
+ LIBRUBY = $(LIBRUBY_SO)
69
+ LIBRUBY_A = lib$(RUBY_SO_NAME)-static.a
70
+ LIBRUBYARG_SHARED = -l$(RUBY_SO_NAME)
71
+ LIBRUBYARG_STATIC = -l$(RUBY_SO_NAME)-static -framework CoreFoundation
72
+ empty =
73
+ OUTFLAG = -o $(empty)
74
+ COUTFLAG = -o $(empty)
75
+ CSRCFLAG = $(empty)
76
+
77
+ RUBY_EXTCONF_H =
78
+ cflags = $(optflags) $(debugflags) $(warnflags)
79
+ cxxflags = $(optflags) $(debugflags) $(warnflags)
80
+ optflags = -O3 -fno-fast-math
81
+ debugflags = -ggdb3
82
+ warnflags = -Wall -Wextra -Wno-unused-parameter -Wno-parentheses -Wno-long-long -Wno-missing-field-initializers -Wno-tautological-compare -Wno-parentheses-equality -Wno-constant-logical-operand -Wno-self-assign -Wunused-variable -Wimplicit-int -Wpointer-arith -Wwrite-strings -Wdeclaration-after-statement -Wshorten-64-to-32 -Wimplicit-function-declaration -Wdivision-by-zero -Wdeprecated-declarations -Wextra-tokens
83
+ CCDLFLAGS = -fno-common
84
+ CFLAGS = $(CCDLFLAGS) $(cflags) -fno-common -pipe -Wall $(ARCH_FLAG)
85
+ INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir)/ruby/backward -I$(hdrdir) -I$(srcdir)
86
+ DEFS =
87
+ CPPFLAGS = -I/usr/local/opt/libyaml/include -I/usr/local/opt/openssl/include -I/usr/local/opt/readline/include -D_XOPEN_SOURCE -D_DARWIN_C_SOURCE -D_DARWIN_UNLIMITED_SELECT -D_REENTRANT $(DEFS) $(cppflags)
88
+ CXXFLAGS = $(CCDLFLAGS) $(cxxflags) $(ARCH_FLAG)
89
+ ldflags = -L. -fstack-protector -L/usr/local/lib -L/usr/local/opt/libyaml/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/readline/lib -framework Carbon -framework ApplicationServices
90
+ dldflags = -Wl,-undefined,dynamic_lookup -Wl,-multiply_defined,suppress -L/usr/local/opt/libyaml/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/readline/lib
91
+ ARCH_FLAG =
92
+ DLDFLAGS = $(ldflags) $(dldflags) $(ARCH_FLAG)
93
+ LDSHARED = $(CC) -dynamic -bundle
94
+ LDSHAREDXX = $(CXX) -dynamic -bundle
95
+ AR = ar
96
+ EXEEXT =
97
+
98
+ RUBY_INSTALL_NAME = $(RUBY_BASE_NAME)
99
+ RUBY_SO_NAME = ruby.2.4.2
100
+ RUBYW_INSTALL_NAME =
101
+ RUBY_VERSION_NAME = $(RUBY_BASE_NAME)-$(ruby_version)
102
+ RUBYW_BASE_NAME = rubyw
103
+ RUBY_BASE_NAME = ruby
104
+
105
+ arch = x86_64-darwin17
106
+ sitearch = $(arch)
107
+ ruby_version = 2.4.0
108
+ ruby = $(bindir)/$(RUBY_BASE_NAME)
109
+ RUBY = $(ruby)
110
+ ruby_headers = $(hdrdir)/ruby.h $(hdrdir)/ruby/backward.h $(hdrdir)/ruby/ruby.h $(hdrdir)/ruby/defines.h $(hdrdir)/ruby/missing.h $(hdrdir)/ruby/intern.h $(hdrdir)/ruby/st.h $(hdrdir)/ruby/subst.h $(arch_hdrdir)/ruby/config.h
111
+
112
+ RM = rm -f
113
+ RM_RF = $(RUBY) -run -e rm -- -rf
114
+ RMDIRS = rmdir -p
115
+ MAKEDIRS = mkdir -p
116
+ INSTALL = /usr/bin/install -c
117
+ INSTALL_PROG = $(INSTALL) -m 0755
118
+ INSTALL_DATA = $(INSTALL) -m 644
119
+ COPY = cp
120
+ TOUCH = exit >
121
+
122
+ #### End of system configuration section. ####
123
+
124
+ preload =
125
+ libpath = . $(libdir) /usr/local/opt/libyaml/lib /usr/local/opt/openssl/lib /usr/local/opt/readline/lib
126
+ LIBPATH = -L. -L$(libdir) -L/usr/local/opt/libyaml/lib -L/usr/local/opt/openssl/lib -L/usr/local/opt/readline/lib
127
+ DEFFILE =
128
+
129
+ CLEANFILES = mkmf.log
130
+ DISTCLEANFILES =
131
+ DISTCLEANDIRS =
132
+
133
+ extout =
134
+ extout_prefix =
135
+ target_prefix =
136
+ LOCAL_LIBS =
137
+ LIBS = $(LIBRUBYARG_SHARED) -lpthread -ldl -lobjc
138
+ ORIG_SRCS = SendThreadSafe.c rbae.c
139
+ SRCS = $(ORIG_SRCS)
140
+ OBJS = SendThreadSafe.o rbae.o
141
+ HDRS = $(srcdir)/SendThreadSafe.h $(srcdir)/osx_ruby.h $(srcdir)/osx_intern.h
142
+ LOCAL_HDRS =
143
+ TARGET = ae
144
+ TARGET_NAME = ae
145
+ TARGET_ENTRY = Init_$(TARGET_NAME)
146
+ DLLIB = $(TARGET).bundle
147
+ EXTSTATIC =
148
+ STATIC_LIB =
149
+
150
+ TIMESTAMP_DIR = .
151
+ BINDIR = $(bindir)
152
+ RUBYCOMMONDIR = $(sitedir)$(target_prefix)
153
+ RUBYLIBDIR = $(sitelibdir)$(target_prefix)
154
+ RUBYARCHDIR = $(sitearchdir)$(target_prefix)
155
+ HDRDIR = $(rubyhdrdir)/ruby$(target_prefix)
156
+ ARCHHDRDIR = $(rubyhdrdir)/$(arch)/ruby$(target_prefix)
157
+ TARGET_SO_DIR =
158
+ TARGET_SO = $(TARGET_SO_DIR)$(DLLIB)
159
+ CLEANLIBS = $(TARGET_SO)
160
+ CLEANOBJS = *.o *.bak
161
+
162
+ all: $(DLLIB)
163
+ static: $(STATIC_LIB)
164
+ .PHONY: all install static install-so install-rb
165
+ .PHONY: clean clean-so clean-static clean-rb
166
+
167
+ clean-static::
168
+ clean-rb-default::
169
+ clean-rb::
170
+ clean-so::
171
+ clean: clean-so clean-static clean-rb-default clean-rb
172
+ -$(Q)$(RM) $(CLEANLIBS) $(CLEANOBJS) $(CLEANFILES) .*.time
173
+
174
+ distclean-rb-default::
175
+ distclean-rb::
176
+ distclean-so::
177
+ distclean-static::
178
+ distclean: clean distclean-so distclean-static distclean-rb-default distclean-rb
179
+ -$(Q)$(RM) Makefile $(RUBY_EXTCONF_H) conftest.* mkmf.log
180
+ -$(Q)$(RM) core ruby$(EXEEXT) *~ $(DISTCLEANFILES)
181
+ -$(Q)$(RMDIRS) $(DISTCLEANDIRS) 2> /dev/null || true
182
+
183
+ realclean: distclean
184
+ install: install-so install-rb
185
+
186
+ install-so: $(DLLIB) $(TIMESTAMP_DIR)/.sitearchdir.time
187
+ $(INSTALL_PROG) $(DLLIB) $(RUBYARCHDIR)
188
+ clean-static::
189
+ -$(Q)$(RM) $(STATIC_LIB)
190
+ install-rb: pre-install-rb do-install-rb install-rb-default
191
+ install-rb-default: pre-install-rb-default do-install-rb-default
192
+ pre-install-rb: Makefile
193
+ pre-install-rb-default: Makefile
194
+ do-install-rb:
195
+ do-install-rb-default:
196
+ pre-install-rb-default: $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
197
+ do-install-rb-default: $(RUBYLIBDIR)/_appscript/defaultterminology.rb
198
+ $(RUBYLIBDIR)/_appscript/defaultterminology.rb: src/lib/_appscript/defaultterminology.rb $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
199
+ $(Q) $(INSTALL_DATA) src/lib/_appscript/defaultterminology.rb $(@D)
200
+ do-install-rb-default: $(RUBYLIBDIR)/_appscript/terminology.rb
201
+ $(RUBYLIBDIR)/_appscript/terminology.rb: src/lib/_appscript/terminology.rb $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
202
+ $(Q) $(INSTALL_DATA) src/lib/_appscript/terminology.rb $(@D)
203
+ do-install-rb-default: $(RUBYLIBDIR)/_appscript/reservedkeywords.rb
204
+ $(RUBYLIBDIR)/_appscript/reservedkeywords.rb: src/lib/_appscript/reservedkeywords.rb $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
205
+ $(Q) $(INSTALL_DATA) src/lib/_appscript/reservedkeywords.rb $(@D)
206
+ do-install-rb-default: $(RUBYLIBDIR)/_appscript/referencerenderer.rb
207
+ $(RUBYLIBDIR)/_appscript/referencerenderer.rb: src/lib/_appscript/referencerenderer.rb $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
208
+ $(Q) $(INSTALL_DATA) src/lib/_appscript/referencerenderer.rb $(@D)
209
+ do-install-rb-default: $(RUBYLIBDIR)/_appscript/safeobject.rb
210
+ $(RUBYLIBDIR)/_appscript/safeobject.rb: src/lib/_appscript/safeobject.rb $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time
211
+ $(Q) $(INSTALL_DATA) src/lib/_appscript/safeobject.rb $(@D)
212
+ pre-install-rb-default: $(TIMESTAMP_DIR)/.sitelibdir.time
213
+ do-install-rb-default: $(RUBYLIBDIR)/rb-scpt.rb
214
+ $(RUBYLIBDIR)/rb-scpt.rb: src/lib/rb-scpt.rb $(TIMESTAMP_DIR)/.sitelibdir.time
215
+ $(Q) $(INSTALL_DATA) src/lib/rb-scpt.rb $(@D)
216
+ do-install-rb-default: $(RUBYLIBDIR)/aem.rb
217
+ $(RUBYLIBDIR)/aem.rb: src/lib/aem.rb $(TIMESTAMP_DIR)/.sitelibdir.time
218
+ $(Q) $(INSTALL_DATA) src/lib/aem.rb $(@D)
219
+ do-install-rb-default: $(RUBYLIBDIR)/kae.rb
220
+ $(RUBYLIBDIR)/kae.rb: src/lib/kae.rb $(TIMESTAMP_DIR)/.sitelibdir.time
221
+ $(Q) $(INSTALL_DATA) src/lib/kae.rb $(@D)
222
+ do-install-rb-default: $(RUBYLIBDIR)/osax.rb
223
+ $(RUBYLIBDIR)/osax.rb: src/lib/osax.rb $(TIMESTAMP_DIR)/.sitelibdir.time
224
+ $(Q) $(INSTALL_DATA) src/lib/osax.rb $(@D)
225
+ pre-install-rb-default: $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
226
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/mactypes.rb
227
+ $(RUBYLIBDIR)/_aem/mactypes.rb: src/lib/_aem/mactypes.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
228
+ $(Q) $(INSTALL_DATA) src/lib/_aem/mactypes.rb $(@D)
229
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/encodingsupport.rb
230
+ $(RUBYLIBDIR)/_aem/encodingsupport.rb: src/lib/_aem/encodingsupport.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
231
+ $(Q) $(INSTALL_DATA) src/lib/_aem/encodingsupport.rb $(@D)
232
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/aemreference.rb
233
+ $(RUBYLIBDIR)/_aem/aemreference.rb: src/lib/_aem/aemreference.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
234
+ $(Q) $(INSTALL_DATA) src/lib/_aem/aemreference.rb $(@D)
235
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/send.rb
236
+ $(RUBYLIBDIR)/_aem/send.rb: src/lib/_aem/send.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
237
+ $(Q) $(INSTALL_DATA) src/lib/_aem/send.rb $(@D)
238
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/codecs.rb
239
+ $(RUBYLIBDIR)/_aem/codecs.rb: src/lib/_aem/codecs.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
240
+ $(Q) $(INSTALL_DATA) src/lib/_aem/codecs.rb $(@D)
241
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/typewrappers.rb
242
+ $(RUBYLIBDIR)/_aem/typewrappers.rb: src/lib/_aem/typewrappers.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
243
+ $(Q) $(INSTALL_DATA) src/lib/_aem/typewrappers.rb $(@D)
244
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/findapp.rb
245
+ $(RUBYLIBDIR)/_aem/findapp.rb: src/lib/_aem/findapp.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
246
+ $(Q) $(INSTALL_DATA) src/lib/_aem/findapp.rb $(@D)
247
+ do-install-rb-default: $(RUBYLIBDIR)/_aem/connect.rb
248
+ $(RUBYLIBDIR)/_aem/connect.rb: src/lib/_aem/connect.rb $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time
249
+ $(Q) $(INSTALL_DATA) src/lib/_aem/connect.rb $(@D)
250
+ pre-install-rb-default:
251
+ $(Q1:0=@$(MAKE) -q do-install-rb-default || )$(ECHO1:0=echo) installing default ae libraries
252
+ $(TIMESTAMP_DIR)/.sitearchdir.time:
253
+ $(Q) $(MAKEDIRS) $(@D) $(RUBYARCHDIR)
254
+ $(Q) $(TOUCH) $@
255
+ $(TIMESTAMP_DIR)/.sitelibdir.-._appscript.time:
256
+ $(Q) $(MAKEDIRS) $(@D) $(RUBYLIBDIR)/_appscript
257
+ $(Q) $(TOUCH) $@
258
+ $(TIMESTAMP_DIR)/.sitelibdir.time:
259
+ $(Q) $(MAKEDIRS) $(@D) $(RUBYLIBDIR)
260
+ $(Q) $(TOUCH) $@
261
+ $(TIMESTAMP_DIR)/.sitelibdir.-._aem.time:
262
+ $(Q) $(MAKEDIRS) $(@D) $(RUBYLIBDIR)/_aem
263
+ $(Q) $(TOUCH) $@
264
+
265
+ site-install: site-install-so site-install-rb
266
+ site-install-so: install-so
267
+ site-install-rb: install-rb
268
+
269
+ .SUFFIXES: .c .m .cc .mm .cxx .cpp .o .S
270
+
271
+ .cc.o:
272
+ $(ECHO) compiling $(<)
273
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
274
+
275
+ .cc.S:
276
+ $(ECHO) translating $(<)
277
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
278
+
279
+ .mm.o:
280
+ $(ECHO) compiling $(<)
281
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
282
+
283
+ .mm.S:
284
+ $(ECHO) translating $(<)
285
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
286
+
287
+ .cxx.o:
288
+ $(ECHO) compiling $(<)
289
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
290
+
291
+ .cxx.S:
292
+ $(ECHO) translating $(<)
293
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
294
+
295
+ .cpp.o:
296
+ $(ECHO) compiling $(<)
297
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
298
+
299
+ .cpp.S:
300
+ $(ECHO) translating $(<)
301
+ $(Q) $(CXX) $(INCFLAGS) $(CPPFLAGS) $(CXXFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
302
+
303
+ .c.o:
304
+ $(ECHO) compiling $(<)
305
+ $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
306
+
307
+ .c.S:
308
+ $(ECHO) translating $(<)
309
+ $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
310
+
311
+ .m.o:
312
+ $(ECHO) compiling $(<)
313
+ $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -c $(CSRCFLAG)$<
314
+
315
+ .m.S:
316
+ $(ECHO) translating $(<)
317
+ $(Q) $(CC) $(INCFLAGS) $(CPPFLAGS) $(CFLAGS) $(COUTFLAG)$@ -S $(CSRCFLAG)$<
318
+
319
+ $(TARGET_SO): $(OBJS) Makefile
320
+ $(ECHO) linking shared-object $(DLLIB)
321
+ -$(Q)$(RM) $(@)
322
+ $(Q) $(LDSHARED) -o $@ $(OBJS) $(LIBPATH) $(DLDFLAGS) $(LOCAL_LIBS) $(LIBS)
323
+ $(Q) $(POSTLINK)
324
+
325
+
326
+
327
+ $(OBJS): $(HDRS) $(ruby_headers)
@@ -0,0 +1,8 @@
1
+ # rb-scpt
2
+
3
+ ## Overview
4
+ Ruby AppleScript (rb-scpt) is a high-level, user-friendly Apple event bridge that allows you to control scriptable Mac OS X applications using ordinary Ruby scripts.
5
+
6
+ ## Contributing
7
+
8
+ All contributions to this repo are welcome, in fact wanted. Please ensure that all work is done off of the `develop` branch with a PR back into master. New versions of the gem will be built from master.
@@ -0,0 +1,31 @@
1
+ require "rake/testtask"
2
+
3
+ task :default => :test
4
+
5
+ task :default => :build
6
+ task :test => :build
7
+
8
+ task :build do
9
+ sh "make"
10
+ end
11
+
12
+ task :build => %w[Makefile ae.bundle]
13
+
14
+ file "Makefile" do
15
+ ruby "extconf.rb"
16
+ end
17
+
18
+ deps = %w[SendThreadSafe rbae]
19
+
20
+ file "ae.bundle" => deps.map { |dep| "#{dep}.o" }
21
+
22
+ deps.each do |dep|
23
+ file "#{dep}.o" => "src/#{dep}.c"
24
+ end
25
+
26
+ Rake::TestTask.new do |t|
27
+ t.libs << "src/lib" << "."
28
+ t.test_files = FileList['test/test_*.rb']
29
+ t.verbose = true
30
+ t.loader = :direct
31
+ end
data/extconf.rb CHANGED
@@ -53,8 +53,6 @@ new_filename_prefix = 'osx_'
53
53
  $stderr.puts "create #{File.expand_path(dst_fname)} ..."
54
54
  File.open(dst_fname, 'w') do |dstfile|
55
55
  IO.foreach(src_path) do |line|
56
- line = line.gsub(/\bID\b/, 'RB_ID')
57
- line = line.gsub(/\bT_DATA\b/, 'RB_T_DATA')
58
56
  line = line.gsub(/\b(?:ruby\/)?intern.h\b/, "#{new_filename_prefix}intern.h")
59
57
  line = line.gsub('#include "defines.h"', '#include "ruby/defines.h"') if not is_ruby_18
60
58
  dstfile.puts line
Binary file
@@ -2,7 +2,7 @@ require "rubygems"
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "rb-scpt"
5
- s.version = "1.0.2"
5
+ s.version = "1.0.3"
6
6
  s.homepage = "https://github.com/BrendanThompson/rb-scpt"
7
7
  s.summary="This is a fork of the original rb-appscript. Ruby AppleScript (rb-scpt) is a high-level, user-friendly Apple event bridge that allows you to control scriptable Mac OS X applications using ordinary Ruby scripts."
8
8
  s.files = Dir["**/*"].delete_if { |name| ["MakeFile", "ae.bundle", "mkmf.log", "rbae.o", "SendThreadSafe.o", "src/osx_ruby.h", "src/osx_intern.h"].include?(name) }
@@ -233,7 +233,7 @@ class Codecs
233
233
  case val
234
234
  when AEMReference::Query then val.AEM_pack_self(self)
235
235
 
236
- when Fixnum, Bignum then
236
+ when Integer then
237
237
  if SInt32Bounds === val
238
238
  AE::AEDesc.new(KAE::TypeSInt32, [val].pack('l'))
239
239
  elsif SInt64Bounds === val
@@ -67,11 +67,8 @@ module AEMEncodingSupport
67
67
 
68
68
  end
69
69
 
70
-
71
70
  def AEMEncodingSupport.encoding_support
72
- # get the appropriate module for the Ruby version used
73
- version, sub_version = RUBY_VERSION.split('.').collect {|n| n.to_i} [0, 2]
74
- return (version >= 1 and sub_version >= 9) ? AEMEncodingSupport::EnableStringEncodings : AEMEncodingSupport::DisableStringEncodings
71
+ RUBY_VERSION.to_f >= 1.9 ? EnableStringEncodings : DisableStringEncodings
75
72
  end
76
73
 
77
74
  end
@@ -226,18 +226,19 @@ end
226
226
  # hooks in Module that will hide any defined.
227
227
 
228
228
  class Module
229
- madded = method(:method_added)
230
- define_method(:method_added) do |name|
229
+ alias so_method_added method_added
230
+ def method_added name
231
231
  # puts "ADDED %-32s %s" % [name, self]
232
- result = madded.call(name)
232
+ result = so_method_added(name)
233
233
  if self == Object
234
234
  AS_SafeObject.hide(name)
235
235
  end
236
236
  return result
237
237
  end
238
- mincluded = method(:included)
239
- define_method(:included) do |mod|
240
- result = mincluded.call(mod)
238
+
239
+ alias so_included included
240
+ def included mod
241
+ result = so_included(mod)
241
242
  # puts "INCLUDED %-32s %s" % [mod, self]
242
243
  if mod == Object
243
244
  public_instance_methods(true).each { |name| AS_SafeObject.hide(name) }
@@ -54,7 +54,7 @@ module TerminologyParser
54
54
  end
55
55
 
56
56
  # Ruby 1.9 has changed the way that a character ordinal is obtained
57
- maj, min, rev = RUBY_VERSION.split('.')
57
+ maj, min, _rev = RUBY_VERSION.split('.')
58
58
  if (maj == '1' and min.to_i < 9) # is Ruby 1.8
59
59
  def _length
60
60
  return @_str[@_ptr]
@@ -647,7 +647,7 @@ module OSAX
647
647
  osax_name = osax_name.downcase
648
648
  m = /^(.+).osax$/.match(osax_name)
649
649
  osax_name = m[1] if m != nil
650
- osax_path, terms = OSAXCache.fetch(osax_name) do
650
+ osax_path, _terms = OSAXCache.fetch(osax_name) do
651
651
  raise ArgumentError, "Scripting addition not found: #{original_name.inspect}"
652
652
  end
653
653
  sp = OSAX::SdefParser.new
@@ -1,12 +1,12 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require "_aem/aemreference"
5
5
  require "_aem/typewrappers"
6
6
  require "_aem/codecs"
7
7
 
8
8
 
9
- class TC_AEMReferences < Test::Unit::TestCase
9
+ class TC_AEMReferences < Minitest::Test
10
10
 
11
11
  def test_reference_forms
12
12
  [
@@ -93,21 +93,21 @@ class TC_AEMReferences < Test::Unit::TestCase
93
93
  val2 = DefaultCodecs.unpack(d)
94
94
  assert_equal(val, val2)
95
95
  val2 = DefaultCodecs.unpack(d)
96
- assert_block { val.eql?(val2) }
96
+ assert_predicate val, :eql?, val2
97
97
  val2 = DefaultCodecs.unpack(d)
98
98
  assert_equal(val2, val)
99
99
  val2 = DefaultCodecs.unpack(d)
100
- assert_block { val2.eql?(val) }
100
+ assert_predicate val2, :eql?, val
101
101
  rescue
102
102
  puts 'EXPECTED: ' + res
103
103
  raise
104
104
  end
105
105
  end
106
- assert_not_equal(AEMReference::App.property('ctxt').property('ctxt'), AEMReference::Con.property('ctxt').property('ctxt'))
107
- assert_not_equal(AEMReference::App.property('foob').property('ctxt'), AEMReference::App.property('ctxt').property('ctxt'))
108
- assert_not_equal(AEMReference::App.elements('ctxt').property('ctxt'), AEMReference::App.property('ctxt').property('ctxt'))
109
- assert_not_equal(AEMReference::App.elements('ctxt').property('ctxt'), 333)
110
- assert_not_equal(333, AEMReference::App.property('ctxt').property('ctxt'))
106
+ refute_equal(AEMReference::App.property('ctxt').property('ctxt'), AEMReference::Con.property('ctxt').property('ctxt'))
107
+ refute_equal(AEMReference::App.property('foob').property('ctxt'), AEMReference::App.property('ctxt').property('ctxt'))
108
+ refute_equal(AEMReference::App.elements('ctxt').property('ctxt'), AEMReference::App.property('ctxt').property('ctxt'))
109
+ refute_equal(AEMReference::App.elements('ctxt').property('ctxt'), 333)
110
+ refute_equal(333, AEMReference::App.property('ctxt').property('ctxt'))
111
111
  # # by-filter references do basic type checking to ensure an its-based reference is given
112
112
  assert_raises(TypeError) { AEMReference::App.elements('docu').by_filter(1) }
113
113
 
@@ -1,6 +1,6 @@
1
1
  #!/usr/local/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require 'rb-scpt'
5
5
 
6
6
  # rb-appscript 0.5.0+ should no longer require the following kludge:
@@ -9,7 +9,7 @@ require 'rb-scpt'
9
9
  # end
10
10
  #end
11
11
 
12
- class TC_AppscriptNewApp < Test::Unit::TestCase
12
+ class TC_AppscriptNewApp < Minitest::Test
13
13
 
14
14
  def test_by_name
15
15
  [
@@ -18,7 +18,7 @@ class TC_AppscriptNewApp < Test::Unit::TestCase
18
18
  'System Events'
19
19
  ].each do |name|
20
20
  a = Appscript.app(name)
21
- assert_not_nil(a)
21
+ refute_nil(a)
22
22
  assert_instance_of(Appscript::Application, a)
23
23
  assert_instance_of(Appscript::Reference, a.name)
24
24
  end
@@ -35,7 +35,7 @@ class TC_AppscriptNewApp < Test::Unit::TestCase
35
35
  'com.apple.finder',
36
36
  ].each do |name|
37
37
  a = Appscript.app.by_id(name)
38
- assert_not_nil(a)
38
+ refute_nil(a)
39
39
  assert_instance_of(Appscript::Application, a)
40
40
  assert_instance_of(Appscript::Reference, a.name)
41
41
  end
@@ -67,7 +67,7 @@ class TC_AppscriptNewApp < Test::Unit::TestCase
67
67
  end
68
68
 
69
69
 
70
- class TC_AppscriptCommands < Test::Unit::TestCase
70
+ class TC_AppscriptCommands < Minitest::Test
71
71
 
72
72
  def setup
73
73
  @te = Appscript.app('TextEdit')
@@ -118,7 +118,7 @@ class TC_AppscriptCommands < Test::Unit::TestCase
118
118
 
119
119
  assert_raises(Appscript::CommandError) { @te.documents[10000].get }
120
120
 
121
- assert_instance_of(Fixnum, @te.documents.count)
121
+ assert_kind_of(Integer, @te.documents.count)
122
122
  assert_equal(@te.documents.count, @te.count(:each=>:document))
123
123
  end
124
124
 
@@ -134,7 +134,7 @@ class TC_AppscriptCommands < Test::Unit::TestCase
134
134
  assert_equal(r, @f.items[f].get)
135
135
 
136
136
  assert_equal(@f.home.items.get, @f.home.items.get)
137
- assert_not_equal(@f.disks['non-existent'], @f.disks[1].get)
137
+ refute_equal(@f.disks['non-existent'], @f.disks[1].get)
138
138
  end
139
139
 
140
140
  def test_command_error
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require "rb-scpt"
5
5
 
6
- class TC_AppscriptReferences < Test::Unit::TestCase
6
+ class TC_AppscriptReferences < Minitest::Test
7
7
 
8
8
  def setup
9
9
  @te = Appscript.app('TextEdit')
@@ -96,7 +96,7 @@ class TC_AppscriptReferences < Test::Unit::TestCase
96
96
  val2 = @te.AS_app_data.unpack(d)
97
97
  if val.class == @te.AS_app_data.unpack(d).class # note: Appscript::Reference and Appscript::GenericReference currently aren't comparable with each other, so the next test would always fail for those
98
98
  assert_equal(val, val2)
99
- assert_block { val.eql?(val2) }
99
+ assert_predicate val, :eql?, val2
100
100
  end
101
101
  end
102
102
  end
@@ -1,6 +1,6 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require 'aem'
5
5
  require 'kae'
6
6
  require 'ae'
@@ -27,10 +27,7 @@ def ut16(s)
27
27
  end
28
28
  end
29
29
 
30
-
31
-
32
-
33
- class TC_Codecs < Test::Unit::TestCase
30
+ class TC_Codecs < Minitest::Test
34
31
 
35
32
  def setup
36
33
  @c = AEM::Codecs.new
@@ -144,10 +141,10 @@ class TC_Codecs < Test::Unit::TestCase
144
141
  d = @c.pack(val)
145
142
  val2 = @c.unpack(d)
146
143
  assert_equal(val, val2)
147
- assert_block { val.eql?(val2) }
144
+ assert_predicate val, :eql?, val2
148
145
  val2 = @c.unpack(d)
149
146
  assert_equal(val2, val)
150
- assert_block { val2.eql?(val) }
147
+ assert_predicate val2, :eql?, val
151
148
  end
152
149
  assert_raises(ArgumentError) { AEM::AEType.new(3) }
153
150
  assert_raises(ArgumentError) { AEM::AEType.new("docum") }
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require "_aem/findapp"
5
5
 
6
6
 
7
- class TC_FindApp < Test::Unit::TestCase
7
+ class TC_FindApp < Minitest::Test
8
8
 
9
9
  def test_find
10
10
  [
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require "_aem/mactypes"
5
5
 
6
6
 
7
- class TC_MacTypes < Test::Unit::TestCase
7
+ class TC_MacTypes < Minitest::Test
8
8
 
9
9
  def setup
10
10
  @path1 = `mktemp -t codecs-test`.chomp
@@ -52,7 +52,7 @@ class TC_MacTypes < Test::Unit::TestCase
52
52
  assert_raises(MacTypes::FileNotFoundError) { f.to_file_url } # File not found.
53
53
 
54
54
  assert_equal(MacTypes::Alias.path("/Library/Scripts/"), MacTypes::Alias.path("/Library/Scripts/"))
55
- assert_not_equal(MacTypes::Alias.path("/Library/Scripts/"), MacTypes::Alias.path("/Applications/"))
55
+ refute_equal(MacTypes::Alias.path("/Library/Scripts/"), MacTypes::Alias.path("/Applications/"))
56
56
  end
57
57
 
58
58
 
@@ -71,7 +71,7 @@ class TC_MacTypes < Test::Unit::TestCase
71
71
  assert_raises(MacTypes::FileNotFoundError) { g.to_alias } # File "/non/existent path" not found.
72
72
 
73
73
  assert_equal(MacTypes::FileURL.path("/Library/Scripts/"), MacTypes::FileURL.path("/Library/Scripts/"))
74
- assert_not_equal(MacTypes::FileURL.path("/Library/Scripts/"), MacTypes::FileURL.path("/Applications/"))
75
- assert_not_equal(MacTypes::FileURL.path("/Library/Scripts/"), MacTypes::Alias.path("/Library/Scripts/"))
74
+ refute_equal(MacTypes::FileURL.path("/Library/Scripts/"), MacTypes::FileURL.path("/Applications/"))
75
+ refute_equal(MacTypes::FileURL.path("/Library/Scripts/"), MacTypes::Alias.path("/Library/Scripts/"))
76
76
  end
77
77
  end
@@ -1,9 +1,9 @@
1
1
  #!/usr/bin/ruby -w
2
2
 
3
- require 'test/unit'
3
+ require 'minitest/autorun'
4
4
  require 'osax'
5
5
 
6
- class TC_OSAX < Test::Unit::TestCase
6
+ class TC_OSAX < Minitest::Test
7
7
 
8
8
  def test_1
9
9
  sa = OSAX.osax('Standardadditions')
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rb-scpt
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.2
4
+ version: 1.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - hhas
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2017-10-15 00:00:00.000000000 Z
12
+ date: 2018-07-13 00:00:00.000000000 Z
13
13
  dependencies: []
14
14
  description:
15
15
  email: brendan@btsystems.com.au
@@ -19,6 +19,9 @@ extensions:
19
19
  extra_rdoc_files: []
20
20
  files:
21
21
  - CHANGES
22
+ - Makefile
23
+ - README.md
24
+ - Rakefile
22
25
  - bin/rb-scpt-1.0.0.gem
23
26
  - bin/rb-scpt-1.0.1.gem
24
27
  - doc/aem-manual/01_introduction.html
@@ -65,6 +68,7 @@ files:
65
68
  - doc/osax-manual/index.html
66
69
  - doc/rb-appscript-logo.png
67
70
  - extconf.rb
71
+ - rb-scpt-1.0.2.gem
68
72
  - rb-scpt.gemspec
69
73
  - sample/AB_export_vcard.rb
70
74
  - sample/AB_list_people_with_emails.rb
@@ -111,7 +115,6 @@ files:
111
115
  - test/test_findapp.rb
112
116
  - test/test_mactypes.rb
113
117
  - test/test_osax.rb
114
- - test/testall.sh
115
118
  homepage: https://github.com/BrendanThompson/rb-scpt
116
119
  licenses: []
117
120
  metadata: {}
@@ -131,7 +134,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
131
134
  version: '0'
132
135
  requirements: []
133
136
  rubyforge_project:
134
- rubygems_version: 2.6.13
137
+ rubygems_version: 2.7.6
135
138
  signing_key:
136
139
  specification_version: 4
137
140
  summary: This is a fork of the original rb-appscript. Ruby AppleScript (rb-scpt) is
@@ -1,10 +0,0 @@
1
- #!/bin/bash
2
-
3
- for f in `ls | grep '^test_'`;
4
- do
5
- echo $f
6
- /usr/bin/ruby -w $f
7
- echo
8
- echo
9
- done
10
-