Add bin/uname, fix disk buidling
Disk will now rebuild when userspace/*.c are updated. Make sure you build in userspace/ first!
This commit is contained in:
parent
c9d5e735ed
commit
fd77e36013
2
Makefile
2
Makefile
@ -132,7 +132,7 @@ initrd/boot/kernel: toaruos-kernel
|
||||
hdd:
|
||||
@mkdir hdd
|
||||
|
||||
toaruos-disk.img: hdd hdd/bs.bmp
|
||||
toaruos-disk.img: hdd hdd/bs.bmp userspace/*.c
|
||||
@${BEG} "hdd" "Generating a Hard Disk image..."
|
||||
@-rm -f toaruos-disk.img
|
||||
@${GENEXT} -d hdd -q -b 131072 -N 4096 toaruos-disk.img ${ERRORS}
|
||||
|
15
userspace/uname.c
Normal file
15
userspace/uname.c
Normal file
@ -0,0 +1,15 @@
|
||||
/* vim: tabstop=4 shiftwidth=4 noexpandtab
|
||||
*
|
||||
* uname
|
||||
*/
|
||||
#include <stdio.h>
|
||||
#include <syscall.h>
|
||||
|
||||
DEFN_SYSCALL1(kernel_string_XXX, 25, char *);
|
||||
|
||||
int main(int argc, char * argv[]) {
|
||||
char _uname[1024];
|
||||
syscall_kernel_string_XXX(_uname);
|
||||
|
||||
fprintf(stdout, "%s\n", _uname);
|
||||
}
|
Loading…
x
Reference in New Issue
Block a user