[readelf] Build environment setup

This commit is contained in:
Kevin Lange 2011-04-06 16:54:57 -05:00
parent 9b3c3a1e60
commit d5a3728b12
2 changed files with 15 additions and 4 deletions

View File

@ -15,13 +15,14 @@ MODULES = $(patsubst %.c,%.o,$(wildcard kernel/core/*.c))
FILESYSTEMS = $(patsubst %.c,%.o,$(wildcard kernel/core/fs/*.c))
VIDEODRIVERS = $(patsubst %.c,%.o,$(wildcard kernel/core/video/*.c))
BINARIES = initrd/bin/test
UTILITIES = util/bin/readelf
EMU = qemu
GENEXT = genext2fs
DD = dd conv=notrunc
.PHONY: all system clean install run docs
.PHONY: all system clean install run docs utils
all: system bootdisk.img docs
all: system bootdisk.img docs utils
system: toaruos-initrd toaruos-kernel
install: toaruos-initrd toaruos-kernel
@ -33,17 +34,19 @@ install: toaruos-initrd toaruos-kernel
run: toaruos-kernel toaruos-initrd
${EMU} -kernel toaruos-kernel -initrd toaruos-initrd -append vid=qemu -serial stdio -vga std
utils: ${UTILITIES}
#################
# Documentation #
#################
docs: docs/core.pdf
docs/core.pdf: docs/*.tex
@${ECHO} -n "\033[32m docs Generating documentation..."
@${ECHO} -n "\033[32m docs Generating documentation...\033[0m"
@pdflatex -draftmode -halt-on-error -output-directory docs/ docs/core.tex > /dev/null
@makeindex -q docs/*.idx
@pdflatex -halt-on-error -output-directory docs/ docs/core.tex > /dev/null
@${ECHO} "\r\033[32;1m docs Generated documentation PDF."
@${ECHO} "\r\033[32;1m docs Generated documentation PDF.\033[0m"
################
# Kernel #
@ -96,6 +99,10 @@ util/bin/mrboots-installer: util/mrboots-installer.c
@${CC} ${NATIVEFLAGS} -o $@ $<
@${ECHO} "\r\033[32;1m CC $<\033[0m"
util/bin/readelf: util/readelf.c
@${ECHO} -n "\033[32m CC $<\033[0m"
@${CC} ${NATIVEFLAGS} -o $@ $<
@${ECHO} "\r\033[32;1m CC $<\033[0m"
################
# Userspace #

View File

@ -7,3 +7,7 @@
/* The Master ELF Header */
#include "../kernel/include/elf.h"
int main(int argc, char ** argv) {
return -1;
}