From 8c6afa35bea1a5ea8a94a3c60d1988999cb41bcc Mon Sep 17 00:00:00 2001 From: jhb Date: Tue, 11 Dec 2001 00:49:34 +0000 Subject: - Add 'fwrite' and 'fseek' words for writing to and seeking on files. - Change the 'fopen' keyword to accept a mode parameter. Note that this will break existing 4th scripts that use fopen. Thus, the loader version has been bumped and loader.4th has been changed to check for a sufficient version on i386 and alpha. Be sure that you either do a full world build or install or full build and install of sys/boot after this since loader.old won't work with the new 4th files and vice versa. PR: kern/32389 Submitted by: Jonathan Mini Sponsored by: ClickArray, Inc. --- share/examples/bootforth/boot.4th | 6 +++--- share/examples/bootforth/loader.rc | 6 +++--- 2 files changed, 6 insertions(+), 6 deletions(-) (limited to 'share/examples/bootforth') diff --git a/share/examples/bootforth/boot.4th b/share/examples/bootforth/boot.4th index 631775b..8f26e0d 100644 --- a/share/examples/bootforth/boot.4th +++ b/share/examples/bootforth/boot.4th @@ -7,15 +7,15 @@ cr .( Loading Forth extensions:) cr .( - screen.4th...) -s" /boot/screen.4th" fopen dup fload fclose +s" /boot/screen.4th" O_RDONLY fopen dup fload fclose \ Load frame support cr .( - frames.4th...) -s" /boot/frames.4th" fopen dup fload fclose +s" /boot/frames.4th" O_RDONLY fopen dup fload fclose \ Load our little menu cr .( - menu.4th...) -s" /boot/menu.4th" fopen dup fload fclose +s" /boot/menu.4th" O_RDONLY fopen dup fload fclose \ Show it cr diff --git a/share/examples/bootforth/loader.rc b/share/examples/bootforth/loader.rc index d216a46..617bc3d 100644 --- a/share/examples/bootforth/loader.rc +++ b/share/examples/bootforth/loader.rc @@ -13,15 +13,15 @@ include /boot/loader.4th \ Load the screen manipulation words cr .( - screen.4th...) -s" /boot/screen.4th" fopen dup fload fclose +s" /boot/screen.4th" O_RDONLY fopen dup fload fclose \ Load frame support cr .( - frames.4th...) -s" /boot/frames.4th" fopen dup fload fclose +s" /boot/frames.4th" O_RDONLY fopen dup fload fclose \ Load our little menu cr .( - menuconf.4th...) -s" /boot/menuconf.4th" fopen dup fload fclose +s" /boot/menuconf.4th" O_RDONLY fopen dup fload fclose \ Initialize loader.4th stuff -- cgit v1.1