Commit a99b2e7b authored by Ben Avison's avatar Ben Avison Committed by ROOL
Browse files

Minor improvements

A few misfeatures were discovered when rewriting the Makefile (see next
commit). These fixes affect the binary outputs:

* Module builds (the normal case) were disabling stack limit checks. Yet the
  code executes in USR mode with a chunked stack in application space, so this
  is potentially unsafe because it could lead to untrapped stack overflows.
* The `Export` file was being unconditionally reinstalled in ResourceFS at
  runtime, duplicating the file that is installed via the Messages module.
* Application (disc and debug) builds were linking with the RISC_OSLib binary
  that was intended for module targets.
* WimpSlot size in application builds was too small to permit it to run.
parent 5ab12b59
......@@ -42,7 +42,11 @@ RESDIR = <resource$dir>.Resources.${COMPONENT}
RESAPP = <resource$dir>.Apps.${APP}
include StdTools
ifeq ($(filter rom%,${MAKECMDGOALS}),)
include AppLibs
include ModuleLibs
......@@ -78,7 +82,7 @@ OBJSD = od.edit od.editv od.message od.slist
.SUFFIXES: .oz .od
.c.o:; ${CC} ${CFLAGS} -c ${C_NO_FNAMES} $<
.c.oz:; ${CC} ${CFLAGS} -c ${C_NO_FNAMES} ${C_MODULE} ${C_NO_STKCHK} -o $@ $<
.c.oz:; ${CC} ${CFLAGS} -c ${C_NO_FNAMES} ${C_MODULE} -o $@ $<
.c.od:; ${CC} ${CFLAGS} -c -DTRACE=1 -g -o $@ $<
.s.o:; ${AS} ${ASFLAGS} $< $@
......@@ -3,7 +3,6 @@
Set Edit$Dir <Obey$Dir>
SetMacro Edit$Path <Edit$Dir>.
Run Edit:!Boot
WimpSlot -min 188k
WimpSlot -min 150k -max 150k
WimpSlot -min 184k -max 184k
Run Edit:Export
Run Edit:!RunImage %*0
......@@ -14,6 +14,6 @@
; > ResFiles
ResourceFile Resources.Export, Resources.Edit.Export
; ResourceFile Resources.Export, Resources.Edit.Export
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment