@profoundlogic/codermake 2.2.0 → 3.0.0
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.
- package/README.md +40 -0
- package/dist/bin/index.js +1 -1
- package/dist/bin/preprocess-rpg-copy.js +1 -1
- package/dist/bin/rdf-to-dds.js +1 -1
- package/dist/lib/config.js +1 -0
- package/dist/lib/discovery.js +1 -1
- package/dist/lib/ejs-to-dds.js +1 -1
- package/dist/lib/executor.js +1 -1
- package/dist/lib/generate-rdf-dds.js +1 -1
- package/dist/lib/license.js +1 -1
- package/dist/lib/makefile-generator.js +1 -1
- package/dist/lib/platform.js +1 -1
- package/dist/lib/preprocessor.js +1 -1
- package/dist/lib/rdf-to-post-data.js +1 -1
- package/dist/lib/rpg-copy-preprocessor.js +1 -1
- package/dist/lib/ssh.js +1 -1
- package/dist/lib/writer.js +1 -1
- package/dist/makefiles/Makefile +5 -0
- package/dist/makefiles/ibmi.mk +32 -32
- package/dist/makefiles/unix.mk +32 -32
- package/package.json +1 -1
- package/skills/codermake/SKILL.md +35 -0
package/dist/makefiles/ibmi.mk
CHANGED
|
@@ -131,7 +131,7 @@ define BUILD_RPGLE_PGM
|
|
|
131
131
|
$(call SETUP_LOG,$(notdir $@))
|
|
132
132
|
$(call RPG_PREPROCESS_SOURCES,$< $(filter-out $(TARGET_LIB_PATH)/%,$^))
|
|
133
133
|
$(SET_LIBL)
|
|
134
|
-
system "crtbndrpg pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') incdir('$$RPG_SRC_ROOT') tgtccsid(*job) output(*print)
|
|
134
|
+
system "crtbndrpg pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') incdir('$$RPG_SRC_ROOT') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtbndrpg)"
|
|
135
135
|
$(call RPG_CLEANUP_SOURCES)
|
|
136
136
|
endef
|
|
137
137
|
|
|
@@ -140,7 +140,7 @@ define BUILD_SQLRPGLE_PGM
|
|
|
140
140
|
$(call SETUP_LOG,$(notdir $@))
|
|
141
141
|
$(call RPG_PREPROCESS_SOURCES,$< $(filter-out $(TARGET_LIB_PATH)/%,$^))
|
|
142
142
|
$(SET_LIBL)
|
|
143
|
-
system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*pgm) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''$$RPG_SRC_ROOT'') tgtccsid(*job) output(*print)')
|
|
143
|
+
system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*pgm) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''$$RPG_SRC_ROOT'') tgtccsid(*job) output(*print)$(CODERMAKE_COMPILEOPT_crtsqlrpgi)')$(CODERMAKE_OPTS_crtsqlrpgi)"
|
|
144
144
|
$(call RPG_CLEANUP_SOURCES)
|
|
145
145
|
endef
|
|
146
146
|
|
|
@@ -149,7 +149,7 @@ define BUILD_RPGLE_MODULE
|
|
|
149
149
|
$(call SETUP_LOG,$(notdir $@))
|
|
150
150
|
$(call RPG_PREPROCESS_SOURCES,$< $(filter-out $(TARGET_LIB_PATH)/%,$^))
|
|
151
151
|
$(SET_LIBL)
|
|
152
|
-
system "crtrpgmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') incdir('$$RPG_SRC_ROOT') tgtccsid(*job) output(*print)
|
|
152
|
+
system "crtrpgmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') incdir('$$RPG_SRC_ROOT') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtrpgmod)"
|
|
153
153
|
$(call RPG_CLEANUP_SOURCES)
|
|
154
154
|
endef
|
|
155
155
|
|
|
@@ -158,7 +158,7 @@ define BUILD_SQLRPGLE_MODULE
|
|
|
158
158
|
$(call SETUP_LOG,$(notdir $@))
|
|
159
159
|
$(call RPG_PREPROCESS_SOURCES,$< $(filter-out $(TARGET_LIB_PATH)/%,$^))
|
|
160
160
|
$(SET_LIBL)
|
|
161
|
-
system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*module) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''$$RPG_SRC_ROOT'') tgtccsid(*job) output(*print)')
|
|
161
|
+
system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*module) srcstmf('$$RPG_SRC_ROOT/$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''$$RPG_SRC_ROOT'') tgtccsid(*job) output(*print)$(CODERMAKE_COMPILEOPT_crtsqlrpgi)')$(CODERMAKE_OPTS_crtsqlrpgi)"
|
|
162
162
|
$(call RPG_CLEANUP_SOURCES)
|
|
163
163
|
endef
|
|
164
164
|
|
|
@@ -166,14 +166,14 @@ endef
|
|
|
166
166
|
define BUILD_CBLLE_PGM
|
|
167
167
|
$(call SETUP_LOG,$(notdir $@))
|
|
168
168
|
$(SET_LIBL)
|
|
169
|
-
system "crtbndcbl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)
|
|
169
|
+
system "crtbndcbl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtbndcbl)"
|
|
170
170
|
endef
|
|
171
171
|
|
|
172
172
|
# Build ILE COBOL module
|
|
173
173
|
define BUILD_CBLLE_MODULE
|
|
174
174
|
$(call SETUP_LOG,$(notdir $@))
|
|
175
175
|
$(SET_LIBL)
|
|
176
|
-
system "crtcblmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)
|
|
176
|
+
system "crtcblmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtcblmod)"
|
|
177
177
|
endef
|
|
178
178
|
|
|
179
179
|
# Build ILE CL program (bound)
|
|
@@ -184,7 +184,7 @@ $(SET_LIBL)
|
|
|
184
184
|
$(DETECT_IBMI_RELEASE)
|
|
185
185
|
TGTCCSID_PARM=
|
|
186
186
|
if [ "$$IBMI_VERSION" -gt 7 ] || { [ "$$IBMI_VERSION" -eq 7 ] && [ "$$IBMI_RELEASE" -ge 5 ]; }; then TGTCCSID_PARM="tgtccsid(*job)"; fi
|
|
187
|
-
system "crtbndcl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)
|
|
187
|
+
system "crtbndcl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)$(CODERMAKE_OPTS_crtbndcl)"
|
|
188
188
|
endef
|
|
189
189
|
|
|
190
190
|
# Build OPM CL program
|
|
@@ -192,7 +192,7 @@ define BUILD_CLP_PGM
|
|
|
192
192
|
$(call SETUP_LOG,$(notdir $@))
|
|
193
193
|
$(call CREATE_SOURCE_MEMBER,$<,qclsrc)
|
|
194
194
|
$(SET_LIBL)
|
|
195
|
-
system "crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) output(*print)"
|
|
195
|
+
system "crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) output(*print)$(CODERMAKE_OPTS_crtclpgm)"
|
|
196
196
|
endef
|
|
197
197
|
|
|
198
198
|
# Build System/38 compatible OPM CL program (QSYS38/CRTCLPGM).
|
|
@@ -203,7 +203,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
203
203
|
$(call CREATE_SOURCE_MEMBER,$<,qclsrc)
|
|
204
204
|
$(SET_LIBL)
|
|
205
205
|
if test -e '$(TARGET_LIB_PATH)/$(call ibmi_name,$@).pgm'; then system "dltpgm $(TARGET_LIB)/$(call ibmi_name_sh,$@)"; fi
|
|
206
|
-
system "qsys38/crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source)"
|
|
206
|
+
system "qsys38/crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_qsys38_crtclpgm))$(CODERMAKE_OPTS_qsys38_crtclpgm)"
|
|
207
207
|
endef
|
|
208
208
|
|
|
209
209
|
# Build RPG/400 (RPG III) program (CRTRPGPGM). Creates the program source
|
|
@@ -213,7 +213,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
213
213
|
$(call CREATE_SOURCE_MEMBER,$<,qrpgsrc)
|
|
214
214
|
$(foreach c,$(RPG3_COPY_MEMBERS),$(call CREATE_COPY_MEMBER,$(c),$(call copy_src_file,$(c)),$(call copy_src_lib,$(c)))$(NL))
|
|
215
215
|
$(SET_LIBL)
|
|
216
|
-
system "crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source) replace(*yes)"
|
|
216
|
+
system "crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_crtrpgpgm)) replace(*yes)$(CODERMAKE_OPTS_crtrpgpgm)"
|
|
217
217
|
endef
|
|
218
218
|
|
|
219
219
|
# Build System/38 compatible RPG III program (QSYS38/CRTRPGPGM).
|
|
@@ -225,7 +225,7 @@ $(call CREATE_SOURCE_MEMBER,$<,qrpgsrc)
|
|
|
225
225
|
$(foreach c,$(RPG3_COPY_MEMBERS),$(call CREATE_COPY_MEMBER,$(c),$(call copy_src_file,$(c)),$(call copy_src_lib,$(c)))$(NL))
|
|
226
226
|
$(SET_LIBL)
|
|
227
227
|
if test -e '$(TARGET_LIB_PATH)/$(call ibmi_name,$@).pgm'; then system "dltpgm $(TARGET_LIB)/$(call ibmi_name_sh,$@)"; fi
|
|
228
|
-
system "qsys38/crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source)"
|
|
228
|
+
system "qsys38/crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_qsys38_crtrpgpgm))$(CODERMAKE_OPTS_qsys38_crtrpgpgm)"
|
|
229
229
|
endef
|
|
230
230
|
|
|
231
231
|
# Build ILE CL module
|
|
@@ -236,28 +236,28 @@ $(SET_LIBL)
|
|
|
236
236
|
$(DETECT_IBMI_RELEASE)
|
|
237
237
|
TGTCCSID_PARM=
|
|
238
238
|
if [ "$$IBMI_VERSION" -gt 7 ] || { [ "$$IBMI_VERSION" -eq 7 ] && [ "$$IBMI_RELEASE" -ge 5 ]; }; then TGTCCSID_PARM="tgtccsid(*job)"; fi
|
|
239
|
-
system "crtclmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)
|
|
239
|
+
system "crtclmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)$(CODERMAKE_OPTS_crtclmod)"
|
|
240
240
|
endef
|
|
241
241
|
|
|
242
242
|
# Build program from modules
|
|
243
243
|
define BUILD_MODULE_TO_PGM
|
|
244
244
|
$(call SETUP_LOG,$(notdir $@))
|
|
245
245
|
$(SET_LIBL)
|
|
246
|
-
system "crtpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)"
|
|
246
|
+
system "crtpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtpgm)"
|
|
247
247
|
endef
|
|
248
248
|
|
|
249
249
|
# Build service program from modules
|
|
250
250
|
define BUILD_MODULE_TO_SRVPGM
|
|
251
251
|
$(call SETUP_LOG,$(notdir $@))
|
|
252
252
|
$(SET_LIBL)
|
|
253
|
-
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*srcfile) srcstmf('$(call shell_escape_dollars,$(filter %.exports %.bnd,$^))') $(BNDSRVPGM_PARM) $(BNDDIR_PARM)"
|
|
253
|
+
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*srcfile) srcstmf('$(call shell_escape_dollars,$(filter %.exports %.bnd,$^))') $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtsrvpgm)"
|
|
254
254
|
endef
|
|
255
255
|
|
|
256
256
|
# Build service program from modules (export all procedures)
|
|
257
257
|
define BUILD_MODULE_TO_SRVPGM_ALL
|
|
258
258
|
$(call SETUP_LOG,$(notdir $@))
|
|
259
259
|
$(SET_LIBL)
|
|
260
|
-
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*all) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)"
|
|
260
|
+
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*all) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtsrvpgm)"
|
|
261
261
|
endef
|
|
262
262
|
|
|
263
263
|
# Build display file
|
|
@@ -265,7 +265,7 @@ define BUILD_DSPF_TO_FILE
|
|
|
265
265
|
$(call SETUP_LOG,$(notdir $@))
|
|
266
266
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
267
267
|
$(SET_LIBL)
|
|
268
|
-
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
268
|
+
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtdspf)"
|
|
269
269
|
endef
|
|
270
270
|
|
|
271
271
|
# Build display file from RDF (Rich Display File) JSON
|
|
@@ -274,7 +274,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
274
274
|
'$(CODERMAKE_NODE)' '$(CODERMAKE_PACKAGE_DIR)/bin/rdf-to-dds.js' '$<' 'tmp/$(basename $(@F)).dspf'
|
|
275
275
|
$(call CREATE_SOURCE_MEMBER,tmp/$(basename $(@F)).dspf,qddssrc)
|
|
276
276
|
$(SET_LIBL)
|
|
277
|
-
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc)
|
|
277
|
+
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc)$(CODERMAKE_OPTS_crtdspf)"
|
|
278
278
|
rm -f 'tmp/$(basename $(@F)).dspf'
|
|
279
279
|
endef
|
|
280
280
|
|
|
@@ -283,7 +283,7 @@ define BUILD_PF_TO_FILE
|
|
|
283
283
|
$(call SETUP_LOG,$(notdir $@))
|
|
284
284
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
285
285
|
$(SET_LIBL)
|
|
286
|
-
system "crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))
|
|
286
|
+
system "crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtpf)"
|
|
287
287
|
endef
|
|
288
288
|
|
|
289
289
|
# Build logical file
|
|
@@ -291,7 +291,7 @@ define BUILD_LF_TO_FILE
|
|
|
291
291
|
$(call SETUP_LOG,$(notdir $@))
|
|
292
292
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
293
293
|
$(SET_LIBL)
|
|
294
|
-
system "crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
294
|
+
system "crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtlf)"
|
|
295
295
|
endef
|
|
296
296
|
|
|
297
297
|
# Build printer file
|
|
@@ -299,7 +299,7 @@ define BUILD_PRTF_TO_FILE
|
|
|
299
299
|
$(call SETUP_LOG,$(notdir $@))
|
|
300
300
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
301
301
|
$(SET_LIBL)
|
|
302
|
-
system "crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
302
|
+
system "crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtprtf)"
|
|
303
303
|
endef
|
|
304
304
|
|
|
305
305
|
# Build System/38 display file
|
|
@@ -307,7 +307,7 @@ define BUILD_DSPF38_TO_FILE
|
|
|
307
307
|
$(call SETUP_LOG,$(notdir $@))
|
|
308
308
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
309
309
|
$(SET_LIBL)
|
|
310
|
-
system "qsys38/crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
310
|
+
system "qsys38/crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtdspf)"
|
|
311
311
|
endef
|
|
312
312
|
|
|
313
313
|
# Build System/38 physical file
|
|
@@ -315,7 +315,7 @@ define BUILD_PF38_TO_FILE
|
|
|
315
315
|
$(call SETUP_LOG,$(notdir $@))
|
|
316
316
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
317
317
|
$(SET_LIBL)
|
|
318
|
-
system "qsys38/crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
318
|
+
system "qsys38/crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtpf)"
|
|
319
319
|
endef
|
|
320
320
|
|
|
321
321
|
# Build System/38 logical file
|
|
@@ -323,7 +323,7 @@ define BUILD_LF38_TO_FILE
|
|
|
323
323
|
$(call SETUP_LOG,$(notdir $@))
|
|
324
324
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
325
325
|
$(SET_LIBL)
|
|
326
|
-
system "qsys38/crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
326
|
+
system "qsys38/crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtlf)"
|
|
327
327
|
endef
|
|
328
328
|
|
|
329
329
|
# Build System/38 printer file
|
|
@@ -331,35 +331,35 @@ define BUILD_PRTF38_TO_FILE
|
|
|
331
331
|
$(call SETUP_LOG,$(notdir $@))
|
|
332
332
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
333
333
|
$(SET_LIBL)
|
|
334
|
-
system "qsys38/crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
334
|
+
system "qsys38/crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtprtf)"
|
|
335
335
|
endef
|
|
336
336
|
|
|
337
337
|
# Build SQL table
|
|
338
338
|
define BUILD_SQLTABLE_TO_FILE
|
|
339
339
|
$(call SETUP_LOG,$(notdir $@))
|
|
340
340
|
$(SET_LIBL)
|
|
341
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
341
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
342
342
|
endef
|
|
343
343
|
|
|
344
344
|
# Build SQL index
|
|
345
345
|
define BUILD_SQLINDEX_TO_FILE
|
|
346
346
|
$(call SETUP_LOG,$(notdir $@))
|
|
347
347
|
$(SET_LIBL)
|
|
348
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
348
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
349
349
|
endef
|
|
350
350
|
|
|
351
351
|
# Build SQL view
|
|
352
352
|
define BUILD_SQLVIEW_TO_FILE
|
|
353
353
|
$(call SETUP_LOG,$(notdir $@))
|
|
354
354
|
$(SET_LIBL)
|
|
355
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
355
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
356
356
|
endef
|
|
357
357
|
|
|
358
358
|
# Build SQL procedure
|
|
359
359
|
define BUILD_SQLPROC_TO_PGM
|
|
360
360
|
$(call SETUP_LOG,$(notdir $@))
|
|
361
361
|
$(SET_LIBL)
|
|
362
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
362
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
363
363
|
endef
|
|
364
364
|
|
|
365
365
|
# Build SQL trigger program.
|
|
@@ -368,7 +368,7 @@ endef
|
|
|
368
368
|
define BUILD_SQLTRIGGER_TO_PGM
|
|
369
369
|
$(call SETUP_LOG,$(notdir $@))
|
|
370
370
|
$(SET_LIBL)
|
|
371
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
371
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
372
372
|
endef
|
|
373
373
|
|
|
374
374
|
# Build SQL procedure as a service program.
|
|
@@ -378,7 +378,7 @@ endef
|
|
|
378
378
|
define BUILD_SQLPROC_TO_SRVPGM
|
|
379
379
|
$(call SETUP_LOG,$(notdir $@))
|
|
380
380
|
$(SET_LIBL)
|
|
381
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
381
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
382
382
|
endef
|
|
383
383
|
|
|
384
384
|
# Build SQL UDF (CREATE FUNCTION ... LANGUAGE SQL) as a service program.
|
|
@@ -388,7 +388,7 @@ endef
|
|
|
388
388
|
define BUILD_SQLUDF_TO_SRVPGM
|
|
389
389
|
$(call SETUP_LOG,$(notdir $@))
|
|
390
390
|
$(SET_LIBL)
|
|
391
|
-
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
391
|
+
system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)"
|
|
392
392
|
endef
|
|
393
393
|
|
|
394
394
|
# Build message file from CL commands
|
|
@@ -407,7 +407,7 @@ endef
|
|
|
407
407
|
define BUILD_MENU
|
|
408
408
|
$(call SETUP_LOG,$(notdir $@))
|
|
409
409
|
$(SET_LIBL)
|
|
410
|
-
system "crtmnu menu($(TARGET_LIB)/$(call ibmi_name_sh,$@)) type(*dspf) dspf($(call ibmi_name_sh,$(filter %.file,$^))) msgf($(call ibmi_name_sh,$(filter %.msgf,$^)))
|
|
410
|
+
system "crtmnu menu($(TARGET_LIB)/$(call ibmi_name_sh,$@)) type(*dspf) dspf($(call ibmi_name_sh,$(filter %.file,$^))) msgf($(call ibmi_name_sh,$(filter %.msgf,$^)))$(CODERMAKE_OPTS_crtmnu)"
|
|
411
411
|
endef
|
|
412
412
|
|
|
413
413
|
######
|
package/dist/makefiles/unix.mk
CHANGED
|
@@ -220,7 +220,7 @@ endif
|
|
|
220
220
|
define BUILD_RPGLE_PGM
|
|
221
221
|
$(call SETUP_LOG,$(notdir $@))
|
|
222
222
|
$(call RPG_PREPROCESS_SOURCES,$(filter-out build/%,$^))
|
|
223
|
-
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtbndrpg pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') tgtccsid(*job) output(*print)
|
|
223
|
+
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtbndrpg pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtbndrpg)")
|
|
224
224
|
$(call RPG_CLEANUP_SOURCES)
|
|
225
225
|
touch '$@'
|
|
226
226
|
endef
|
|
@@ -229,7 +229,7 @@ endef
|
|
|
229
229
|
define BUILD_SQLRPGLE_PGM
|
|
230
230
|
$(call SETUP_LOG,$(notdir $@))
|
|
231
231
|
$(call RPG_PREPROCESS_SOURCES,$(filter-out build/%,$^))
|
|
232
|
-
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*pgm) srcstmf('$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''.'') tgtccsid(*job) output(*print)')
|
|
232
|
+
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*pgm) srcstmf('$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''.'') tgtccsid(*job) output(*print)$(CODERMAKE_COMPILEOPT_crtsqlrpgi)')$(CODERMAKE_OPTS_crtsqlrpgi)")
|
|
233
233
|
$(call RPG_CLEANUP_SOURCES)
|
|
234
234
|
touch '$@'
|
|
235
235
|
endef
|
|
@@ -238,7 +238,7 @@ endef
|
|
|
238
238
|
define BUILD_RPGLE_MODULE
|
|
239
239
|
$(call SETUP_LOG,$(notdir $@))
|
|
240
240
|
$(call RPG_PREPROCESS_SOURCES,$(filter-out build/%,$^))
|
|
241
|
-
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtrpgmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') tgtccsid(*job) output(*print)
|
|
241
|
+
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtrpgmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtrpgmod)")
|
|
242
242
|
$(call RPG_CLEANUP_SOURCES)
|
|
243
243
|
touch '$@'
|
|
244
244
|
endef
|
|
@@ -247,7 +247,7 @@ endef
|
|
|
247
247
|
define BUILD_SQLRPGLE_MODULE
|
|
248
248
|
$(call SETUP_LOG,$(notdir $@))
|
|
249
249
|
$(call RPG_PREPROCESS_SOURCES,$(filter-out build/%,$^))
|
|
250
|
-
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*module) srcstmf('$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''.'') tgtccsid(*job) output(*print)')
|
|
250
|
+
$(call REMOTE_BUILD_FROM,$$RPG_SRC_ROOT,$(filter-out build/%,$^),system "crtsqlrpgi obj($(TARGET_LIB)/$(call ibmi_name_sh,$@)) objtype(*module) srcstmf('$(call shell_escape_dollars,$<)') cvtccsid(*job) output(*print) rpgppopt(*lvl2) compileopt('incdir(''.'') tgtccsid(*job) output(*print)$(CODERMAKE_COMPILEOPT_crtsqlrpgi)')$(CODERMAKE_OPTS_crtsqlrpgi)")
|
|
251
251
|
$(call RPG_CLEANUP_SOURCES)
|
|
252
252
|
touch '$@'
|
|
253
253
|
endef
|
|
@@ -255,14 +255,14 @@ endef
|
|
|
255
255
|
# Build ILE COBOL program (bound)
|
|
256
256
|
define BUILD_CBLLE_PGM
|
|
257
257
|
$(call SETUP_LOG,$(notdir $@))
|
|
258
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtbndcbl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)
|
|
258
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtbndcbl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtbndcbl)")
|
|
259
259
|
touch '$@'
|
|
260
260
|
endef
|
|
261
261
|
|
|
262
262
|
# Build ILE COBOL module
|
|
263
263
|
define BUILD_CBLLE_MODULE
|
|
264
264
|
$(call SETUP_LOG,$(notdir $@))
|
|
265
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtcblmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)
|
|
265
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtcblmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') tgtccsid(*job) output(*print)$(CODERMAKE_OPTS_crtcblmod)")
|
|
266
266
|
touch '$@'
|
|
267
267
|
endef
|
|
268
268
|
|
|
@@ -275,7 +275,7 @@ $(call REMOTE_BUILD,$(filter-out build/%,$^),\
|
|
|
275
275
|
$(DETECT_IBMI_RELEASE); \
|
|
276
276
|
TGTCCSID_PARM=; \
|
|
277
277
|
if [ "$$IBMI_VERSION" -gt 7 ] || { [ "$$IBMI_VERSION" -eq 7 ] && [ "$$IBMI_RELEASE" -ge 5 ]; }; then TGTCCSID_PARM="tgtccsid(*job)"; fi; \
|
|
278
|
-
system "crtbndcl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)
|
|
278
|
+
system "crtbndcl pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)$(CODERMAKE_OPTS_crtbndcl)")
|
|
279
279
|
touch '$@'
|
|
280
280
|
endef
|
|
281
281
|
|
|
@@ -285,7 +285,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
285
285
|
$(call CREATE_SOURCE_MEMBER,$<,qclsrc)
|
|
286
286
|
$(SSH) $(QSHELL) <<'EOF'
|
|
287
287
|
$(SET_LIBL)
|
|
288
|
-
system "crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) output(*print)"
|
|
288
|
+
system "crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) output(*print)$(CODERMAKE_OPTS_crtclpgm)"
|
|
289
289
|
EOF
|
|
290
290
|
touch '$@'
|
|
291
291
|
endef
|
|
@@ -301,7 +301,7 @@ $(SSH) $(QSHELL) <<'EOF'
|
|
|
301
301
|
if [ -e '$(TARGET_LIB_PATH)/$(call ibmi_name,$@).pgm' ]; then
|
|
302
302
|
system "dltpgm $(TARGET_LIB)/$(call ibmi_name_sh,$@)"
|
|
303
303
|
fi
|
|
304
|
-
system "qsys38/crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source)"
|
|
304
|
+
system "qsys38/crtclpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qclsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_qsys38_crtclpgm))$(CODERMAKE_OPTS_qsys38_crtclpgm)"
|
|
305
305
|
EOF
|
|
306
306
|
touch '$@'
|
|
307
307
|
endef
|
|
@@ -314,7 +314,7 @@ $(call CREATE_SOURCE_MEMBER,$<,qrpgsrc)
|
|
|
314
314
|
$(foreach c,$(RPG3_COPY_MEMBERS),$(call CREATE_COPY_MEMBER,$(c),$(call copy_src_file,$(c)),$(call copy_src_lib,$(c)))$(NL))
|
|
315
315
|
$(SSH) $(QSHELL) <<'EOF'
|
|
316
316
|
$(SET_LIBL)
|
|
317
|
-
system "crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source) replace(*yes)"
|
|
317
|
+
system "crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_crtrpgpgm)) replace(*yes)$(CODERMAKE_OPTS_crtrpgpgm)"
|
|
318
318
|
EOF
|
|
319
319
|
touch '$@'
|
|
320
320
|
endef
|
|
@@ -331,7 +331,7 @@ $(SSH) $(QSHELL) <<'EOF'
|
|
|
331
331
|
if [ -e '$(TARGET_LIB_PATH)/$(call ibmi_name,$@).pgm' ]; then
|
|
332
332
|
system "dltpgm $(TARGET_LIB)/$(call ibmi_name_sh,$@)"
|
|
333
333
|
fi
|
|
334
|
-
system "qsys38/crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source)"
|
|
334
|
+
system "qsys38/crtrpgpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qrpgsrc) srcmbr($(call ibmi_name_sh,$<)) option(*source$(CODERMAKE_OPTVALS_qsys38_crtrpgpgm))$(CODERMAKE_OPTS_qsys38_crtrpgpgm)"
|
|
335
335
|
EOF
|
|
336
336
|
touch '$@'
|
|
337
337
|
endef
|
|
@@ -345,7 +345,7 @@ $(call REMOTE_BUILD,$(filter-out build/%,$^),\
|
|
|
345
345
|
$(DETECT_IBMI_RELEASE); \
|
|
346
346
|
TGTCCSID_PARM=; \
|
|
347
347
|
if [ "$$IBMI_VERSION" -gt 7 ] || { [ "$$IBMI_VERSION" -eq 7 ] && [ "$$IBMI_RELEASE" -ge 5 ]; }; then TGTCCSID_PARM="tgtccsid(*job)"; fi; \
|
|
348
|
-
system "crtclmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)
|
|
348
|
+
system "crtclmod module($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcstmf('$(call shell_escape_dollars,$<)') incdir('.') $$TGTCCSID_PARM output(*print)$(CODERMAKE_OPTS_crtclmod)")
|
|
349
349
|
touch '$@'
|
|
350
350
|
endef
|
|
351
351
|
|
|
@@ -354,7 +354,7 @@ define BUILD_MODULE_TO_PGM
|
|
|
354
354
|
$(call SETUP_LOG,$(notdir $@))
|
|
355
355
|
$(SSH) $(QSHELL) <<'EOF'
|
|
356
356
|
$(SET_LIBL)
|
|
357
|
-
system "crtpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)"
|
|
357
|
+
system "crtpgm pgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtpgm)"
|
|
358
358
|
EOF
|
|
359
359
|
touch '$@'
|
|
360
360
|
endef
|
|
@@ -362,7 +362,7 @@ endef
|
|
|
362
362
|
# Build service program from modules
|
|
363
363
|
define BUILD_MODULE_TO_SRVPGM
|
|
364
364
|
$(call SETUP_LOG,$(notdir $@))
|
|
365
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*srcfile) srcstmf('$(call shell_escape_dollars,$(filter %.exports %.bnd,$^))') $(BNDSRVPGM_PARM) $(BNDDIR_PARM)")
|
|
365
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*srcfile) srcstmf('$(call shell_escape_dollars,$(filter %.exports %.bnd,$^))') $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtsrvpgm)")
|
|
366
366
|
touch '$@'
|
|
367
367
|
endef
|
|
368
368
|
|
|
@@ -371,7 +371,7 @@ define BUILD_MODULE_TO_SRVPGM_ALL
|
|
|
371
371
|
$(call SETUP_LOG,$(notdir $@))
|
|
372
372
|
$(SSH) $(QSHELL) <<'EOF'
|
|
373
373
|
$(SET_LIBL)
|
|
374
|
-
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*all) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)"
|
|
374
|
+
system "crtsrvpgm srvpgm($(TARGET_LIB)/$(call ibmi_name_sh,$@)) $(MODULE_PARM) export(*all) $(BNDSRVPGM_PARM) $(BNDDIR_PARM)$(CODERMAKE_OPTS_crtsrvpgm)"
|
|
375
375
|
EOF
|
|
376
376
|
touch '$@'
|
|
377
377
|
endef
|
|
@@ -382,7 +382,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
382
382
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
383
383
|
$(SSH) $(QSHELL) <<'EOF'
|
|
384
384
|
$(SET_LIBL)
|
|
385
|
-
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
385
|
+
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtdspf)"
|
|
386
386
|
EOF
|
|
387
387
|
touch '$@'
|
|
388
388
|
endef
|
|
@@ -394,7 +394,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
394
394
|
$(call CREATE_SOURCE_MEMBER,tmp/$(basename $(@F)).dspf,qddssrc)
|
|
395
395
|
$(SSH) $(QSHELL) <<'EOF'
|
|
396
396
|
$(SET_LIBL)
|
|
397
|
-
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc)
|
|
397
|
+
system "crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc)$(CODERMAKE_OPTS_crtdspf)"
|
|
398
398
|
EOF
|
|
399
399
|
rm -f 'tmp/$(basename $(@F)).dspf'
|
|
400
400
|
touch '$@'
|
|
@@ -406,7 +406,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
406
406
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
407
407
|
$(SSH) $(QSHELL) <<'EOF'
|
|
408
408
|
$(SET_LIBL)
|
|
409
|
-
system "crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
409
|
+
system "crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtpf)"
|
|
410
410
|
EOF
|
|
411
411
|
touch '$@'
|
|
412
412
|
endef
|
|
@@ -417,7 +417,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
417
417
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
418
418
|
$(SSH) $(QSHELL) <<'EOF'
|
|
419
419
|
$(SET_LIBL)
|
|
420
|
-
system "crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
420
|
+
system "crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtlf)"
|
|
421
421
|
EOF
|
|
422
422
|
touch '$@'
|
|
423
423
|
endef
|
|
@@ -428,7 +428,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
428
428
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
429
429
|
$(SSH) $(QSHELL) <<'EOF'
|
|
430
430
|
$(SET_LIBL)
|
|
431
|
-
system "crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
431
|
+
system "crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_crtprtf)"
|
|
432
432
|
EOF
|
|
433
433
|
touch '$@'
|
|
434
434
|
endef
|
|
@@ -439,7 +439,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
439
439
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
440
440
|
$(SSH) $(QSHELL) <<'EOF'
|
|
441
441
|
$(SET_LIBL)
|
|
442
|
-
system "qsys38/crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
442
|
+
system "qsys38/crtdspf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtdspf)"
|
|
443
443
|
EOF
|
|
444
444
|
touch '$@'
|
|
445
445
|
endef
|
|
@@ -450,7 +450,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
450
450
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
451
451
|
$(SSH) $(QSHELL) <<'EOF'
|
|
452
452
|
$(SET_LIBL)
|
|
453
|
-
system "qsys38/crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
453
|
+
system "qsys38/crtpf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtpf)"
|
|
454
454
|
EOF
|
|
455
455
|
touch '$@'
|
|
456
456
|
endef
|
|
@@ -461,7 +461,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
461
461
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
462
462
|
$(SSH) $(QSHELL) <<'EOF'
|
|
463
463
|
$(SET_LIBL)
|
|
464
|
-
system "qsys38/crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
464
|
+
system "qsys38/crtlf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtlf)"
|
|
465
465
|
EOF
|
|
466
466
|
touch '$@'
|
|
467
467
|
endef
|
|
@@ -472,7 +472,7 @@ $(call SETUP_LOG,$(notdir $@))
|
|
|
472
472
|
$(call CREATE_SOURCE_MEMBER,$<,qddssrc)
|
|
473
473
|
$(SSH) $(QSHELL) <<'EOF'
|
|
474
474
|
$(SET_LIBL)
|
|
475
|
-
system "qsys38/crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))"
|
|
475
|
+
system "qsys38/crtprtf file($(TARGET_LIB)/$(call ibmi_name_sh,$@)) srcfile($(TARGET_LIB)/qddssrc) srcmbr($(call ibmi_name_sh,$<))$(CODERMAKE_OPTS_qsys38_crtprtf)"
|
|
476
476
|
EOF
|
|
477
477
|
touch '$@'
|
|
478
478
|
endef
|
|
@@ -480,28 +480,28 @@ endef
|
|
|
480
480
|
# Build SQL table
|
|
481
481
|
define BUILD_SQLTABLE_TO_FILE
|
|
482
482
|
$(call SETUP_LOG,$(notdir $@))
|
|
483
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
483
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
484
484
|
touch '$@'
|
|
485
485
|
endef
|
|
486
486
|
|
|
487
487
|
# Build SQL index
|
|
488
488
|
define BUILD_SQLINDEX_TO_FILE
|
|
489
489
|
$(call SETUP_LOG,$(notdir $@))
|
|
490
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
490
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
491
491
|
touch '$@'
|
|
492
492
|
endef
|
|
493
493
|
|
|
494
494
|
# Build SQL view
|
|
495
495
|
define BUILD_SQLVIEW_TO_FILE
|
|
496
496
|
$(call SETUP_LOG,$(notdir $@))
|
|
497
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
497
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
498
498
|
touch '$@'
|
|
499
499
|
endef
|
|
500
500
|
|
|
501
501
|
# Build SQL procedure
|
|
502
502
|
define BUILD_SQLPROC_TO_PGM
|
|
503
503
|
$(call SETUP_LOG,$(notdir $@))
|
|
504
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
504
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
505
505
|
touch '$@'
|
|
506
506
|
endef
|
|
507
507
|
|
|
@@ -510,7 +510,7 @@ endef
|
|
|
510
510
|
# trigger name should map exactly to the build target object.
|
|
511
511
|
define BUILD_SQLTRIGGER_TO_PGM
|
|
512
512
|
$(call SETUP_LOG,$(notdir $@))
|
|
513
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
513
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
514
514
|
touch '$@'
|
|
515
515
|
endef
|
|
516
516
|
|
|
@@ -520,7 +520,7 @@ endef
|
|
|
520
520
|
# its object name from the routine (name it to match the target where practical).
|
|
521
521
|
define BUILD_SQLPROC_TO_SRVPGM
|
|
522
522
|
$(call SETUP_LOG,$(notdir $@))
|
|
523
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
523
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
524
524
|
touch '$@'
|
|
525
525
|
endef
|
|
526
526
|
|
|
@@ -530,7 +530,7 @@ endef
|
|
|
530
530
|
# to match the target where practical).
|
|
531
531
|
define BUILD_SQLUDF_TO_SRVPGM
|
|
532
532
|
$(call SETUP_LOG,$(notdir $@))
|
|
533
|
-
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)')
|
|
533
|
+
$(call REMOTE_BUILD,$(filter-out build/%,$^),system "runsqlstm srcstmf('$(call shell_escape_dollars,$<)') dftrdbcol($(TARGET_LIB))$(CODERMAKE_OPTS_runsqlstm)")
|
|
534
534
|
touch '$@'
|
|
535
535
|
endef
|
|
536
536
|
|
|
@@ -553,7 +553,7 @@ define BUILD_MENU
|
|
|
553
553
|
$(call SETUP_LOG,$(notdir $@))
|
|
554
554
|
$(SSH) $(QSHELL) <<'EOF'
|
|
555
555
|
$(SET_LIBL)
|
|
556
|
-
system "crtmnu menu($(TARGET_LIB)/$(call ibmi_name_sh,$@)) type(*dspf) dspf($(call ibmi_name_sh,$(filter %.file,$^))) msgf($(call ibmi_name_sh,$(filter %.msgf,$^)))
|
|
556
|
+
system "crtmnu menu($(TARGET_LIB)/$(call ibmi_name_sh,$@)) type(*dspf) dspf($(call ibmi_name_sh,$(filter %.file,$^))) msgf($(call ibmi_name_sh,$(filter %.msgf,$^)))$(CODERMAKE_OPTS_crtmnu)"
|
|
557
557
|
EOF
|
|
558
558
|
touch '$@'
|
|
559
559
|
endef
|
package/package.json
CHANGED
|
@@ -255,3 +255,38 @@ When the project has a multi-library layout, `CODERMAKE_LIBRARY_MAP` enables per
|
|
|
255
255
|
| `CODERMAKE_LIBRARY_LIST` | Optional. Space-separated, ordered IBM i library list. Replaces the user portion of the build job's library list. Only valid alongside `CODERMAKE_LIBRARY_MAP`. |
|
|
256
256
|
|
|
257
257
|
When using multi-library output, refer to objects in another library with the qualifier syntax `<libraryDir>/<bareobj>.<ext>` (see *Cross-directory references* above).
|
|
258
|
+
|
|
259
|
+
## Compile options
|
|
260
|
+
|
|
261
|
+
To change the parameters passed to IBM i compile commands (e.g. target
|
|
262
|
+
release, debug view), edit `.codermake/config.json` in the project root — **do
|
|
263
|
+
not edit the Makefiles**. The file is optional; when absent, codermake uses its
|
|
264
|
+
built-in parameters.
|
|
265
|
+
|
|
266
|
+
```json
|
|
267
|
+
{
|
|
268
|
+
"targetRelease": "V7R4M0",
|
|
269
|
+
"compileOptions": {
|
|
270
|
+
"crtbndrpg": { "dbgview": "*all" },
|
|
271
|
+
"crtrpgpgm": { "option": ["*srcdbg"] },
|
|
272
|
+
"runsqlstm": { "commit": "*chg" },
|
|
273
|
+
"crtsqlrpgi": { "dbgview": "*source", "compileopt": { "optimize": "*full" } }
|
|
274
|
+
}
|
|
275
|
+
}
|
|
276
|
+
```
|
|
277
|
+
|
|
278
|
+
- **`targetRelease`** sets `TGTRLS`, applied to each compile command that
|
|
279
|
+
accepts it — do not add `tgtrls` under `compileOptions`.
|
|
280
|
+
- **`compileOptions`** is keyed by lowercase CL command name (`crtbndrpg`,
|
|
281
|
+
`crtsqlrpgi`, `qsys38/crtclpgm`, ...). Each keyword is added to that command;
|
|
282
|
+
values may be a string or an array (`["*a", "*b"]` → `KEYWORD(*A *B)`).
|
|
283
|
+
- **Reserved** parameters that codermake owns (`pgm`, `srcstmf`,
|
|
284
|
+
`output(*print)`, `tgtccsid`, and similar) cannot be overridden — attempting
|
|
285
|
+
to set one is a hard error.
|
|
286
|
+
- `option` and `compileopt` are **augmentable**: your values merge with the
|
|
287
|
+
parts codermake requires (`OPTION` always keeps `*SOURCE`; `COMPILEOPT` keeps
|
|
288
|
+
its `incdir`/`tgtccsid`/`output`).
|
|
289
|
+
|
|
290
|
+
Preview the effect without building: `codermake --print-makefile` shows the
|
|
291
|
+
resolved parameters, and `codermake -n <target>` prints the expanded compile
|
|
292
|
+
command.
|