cd commands && $(MAKE) all
depend::
- mkdep kernel
cd kernel && $(MAKE) $@
cd servers && $(MAKE) $@
cd drivers && $(MAKE) $@
BINDIR?= /usr/sbin
-CPPFLAGS.imgrd.c += -I${.CURDIR}/../ramdisk -T /usr/tmp
+CPPFLAGS.memory.c+= -I${MINIXSRCDIR}
+CPPFLAGS.imgrd.c+= -I${.CURDIR}/../ramdisk -T /usr/tmp
.include <minix.prog.mk>
.include <minix.subdir.mk>
#include <minix/ds.h>
#include <minix/vm.h>
#include <sys/mman.h>
-#include "../../../kernel/const.h"
-#include "../../../kernel/config.h"
-#include "../../../kernel/type.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
#include <machine/vm.h>
BINDIR?= /usr/sbin
+CPPFLAGS.orinoco.c+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
#include <machine/pci.h>
#include <minix/ds.h>
#include <minix/endpoint.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/type.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
#define VERBOSE 1 /* display message during init */
BINDIR?= /usr/sbin
+CPPFLAGS.random.c+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
*/
#include <minix/drivers.h>
-#include "../../kernel/const.h"
+#include "kernel/const.h"
#include "assert.h"
#include "random.h"
BINDIR?= /usr/sbin
+CPPFLAGS+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
#include <assert.h>
#include <unistd.h>
#include <sys/ioc_memory.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/type.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
#define RL_IDR 0x00 /* Ethernet address
* Note: RL_9346CR_EEM_CONFIG mode is
BINDIR?= /usr/sbin
+CPPFLAGS+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
#include <sys/types.h>
#include <assert.h>
#include <unistd.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/type.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
#define debug 1
#define printW() ((void)0)
SUBDIR= keymaps
# Needs kernel/const.h, etc
-CPPFLAGS+= -I ../..
+CPPFLAGS+= -I${MINIXSRCDIR}
.include <minix.prog.mk>
.include <minix.subdir.mk>
#include <minix/com.h>
#include <minix/keymap.h>
#include "tty.h"
-#include <kernel/const.h>
-#include <kernel/config.h>
-#include <kernel/type.h>
-#include <kernel/proc.h>
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
PRIVATE u16_t keymap[NR_SCAN_CODES * MAP_COLS] = {
#include "keymaps/us-std.src"
PRINTOBJDIR= echo # prevent infinite recursion
.endif
+
+
+#
+# Determine if running in the MINIX source tree by checking for the
+# existence of boot/ and tools/ in the current or a parent directory,
+# and setting _MSRC_TOP_ to the result.
+#
+.if !defined(_MSRC_TOP_) # {
+_MSRC_TOP_!= cd ${.CURDIR}; while :; do \
+ here=`pwd`; \
+ [ -d boot ] && [ -d tools ] && { echo $$here; break; }; \
+ case $$here in /) echo ""; break;; esac; \
+ cd ..; done
+
+.MAKEOVERRIDES+= _MSRC_TOP_
+
+.endif # }
+
+#
+# If _MSRC_TOP_ != "", we're within the MINIX source tree, so set
+# defaults for MINIXSRCDIR and _MSRC_TOP_OBJ_.
+#
+.if (${_MSRC_TOP_} != "") # {
+
+MINIXSRCDIR?= ${_MSRC_TOP_}
+
+.if !defined(_MSRC_TOP_OBJ_)
+_MSRC_TOP_OBJ_!= cd ${_MSRC_TOP_} && ${PRINTOBJDIR}
+.MAKEOVERRIDES+= _MSRC_TOP_OBJ_
+.endif
+
+.endif # _MSRC_TOP_ != "" # }
+
+
+
#
# Determine if running in the NetBSD source tree by checking for the
# existence of build.sh and tools/ in the current or a parent directory,
# Makefile for kernel
+.include <minix.own.mk>
-include /etc/make.conf
-
-# Directories
-u = /usr
-i = $u/include
-l = $u/lib
-s = system
-a = arch/$(ARCH)
-
-# Programs, flags, etc.
-CC = exec cc
-CPP = $l/cpp
-LD = $(CC) -.o
-CPPFLAGS=-I$i -I$a/include -I$a
-CFLAGS=$(CPROFILE) $(CPPFLAGS) $(EXTRA_OPTS)
-LDFLAGS=-i
+PROG= kernel
# first-stage, arch-dependent startup code
-HEAD = $a/mpx386.o
-
-OBJS = start.o table.o main.o proc.o \
- system.o clock.o utility.o debug.o profile.o interrupt.o \
- watchdog.o
-SYSTEM = system.a
-ARCHLIB = $a/$(ARCH).a
-LIBS = -ltimers -lsys
+SRCS= mpx.S
+SRCS+= start.c table.c main.c proc.c \
+ system.c clock.c utility.c debug.c profile.c interrupt.c \
+ watchdog.c
-# What to make.
-all: build
-kernel build install: $(OBJS)
- cd system && $(MAKE) $@
- cd $a && $(MAKE) $@
- $(LD) $(CFLAGS) $(LDFLAGS) -o kernel $(HEAD) $(OBJS) \
- $(SYSTEM) $(ARCHLIB) $(LIBS)
- install -S 0 kernel
+DPADD+= ${LIBTIMERS} ${LIBSYS}
+LDADD+= -ltimers -lsys
-clean:
- cd system && $(MAKE) -$(MAKEFLAGS) $@
- cd $a && $(MAKE) -$(MAKEFLAGS) $@
- rm -f *.a *.o *~ *.bak kernel
+LDFLAGS+= -.o
+CPPFLAGS+= -I${.CURDIR}/arch/${ARCH}/include -I${MINIXSRCDIR}
+AFLAGS+= -I${.CURDIR}/arch/${ARCH}/include -I${MINIXSRCDIR}
-depend:
- cd system && $(MAKE) -$(MAKEFLAGS) $@
- cd $a && $(MAKE) $@
- mkdep "$(CC) -E $(CPPFLAGS)" *.c > .depend
+#Tell ASMCONV to prepend underscores to symbols
+ASMCONVFLAGS+= -u
-# How to build it
-.c.o:
- $(CC) $(CFLAGS) -c -o $@ $<
+INSTALLFLAGS+= -S 0
+BINDIR= /usr/sbin
+MAN=
+.include "system/Makefile.inc"
+.include "arch/${ARCH}/Makefile.inc"
+.include <minix.prog.mk>
+++ /dev/null
-# Makefile for kernel
-
-include /etc/make.conf
-
-ARCHAR=$(ARCH).a
-
-# objects, excluding first-stage code, which is $(HEAD).
-# the HEAD variable is passed as an argument to this Makefile
-# by an upper level Makefile.
-
-OBJS= arch_do_vmctl.o \
- breakpoints.o \
- clock.o \
- debugreg.o \
- do_int86.o \
- do_iopenable.o \
- do_readbios.o \
- do_sdevio.o \
- exception.o \
- i8259.o \
- klib386.o \
- memory.o \
- mpx386.o \
- protect.o \
- system.o \
- apic.o \
- apic_asm.o \
- watchdog.o
-
-CPPFLAGS=-Iinclude
-CFLAGS=-Iinclude -Wall $(CPROFILE)
-
-build: $(HEAD) $(ARCHAR)
-
-$(ARCHAR): $(ARCHAR)($(OBJS))
- aal cr $@ $(OBJS)
-# ar cru $(.TARGET) $(.OODATE)
-
-depend:
- mkdep "$(CC) -E $(CPPFLAGS)" *.c *.S > .depend
-
-clean:
- rm -f *.a *.o *~ *.tmp *.s
-
-# How to build it
-klib386.o: klib386.S
- $(CC) $(CFLAGS) -E -D__ASSEMBLY__ -o $@.tmp $<
- gas2ack -u $@.tmp $@.s
- $(CC) $(CFLAGS) -c -o $@ $@.s
-
-mpx386.o: mpx386.S
- $(CC) $(CFLAGS) -E -D__ASSEMBLY__ -o $@.tmp $<
- gas2ack -u $@.tmp $@.s
- $(CC) $(CFLAGS) -c -o $@ $@.s
-
-apic_asm.o: apic_asm.S
- $(CC) $(CFLAGS) -E -D__ASSEMBLY__ -o $@.tmp $<
- gas2ack -u $@.tmp $@.s
- $(CC) $(CFLAGS) -c -o $@ $@.s
-
-debugreg.o: debugreg.S
- $(CC) $(CFLAGS) -E -D__ASSEMBLY__ -o $@.tmp $<
- gas2ack -u $@.tmp $@.s
- $(CC) $(CFLAGS) -c -o $@ $@.s
-
-$(HEAD): mpx386.o
- cp $< $@
-
--- /dev/null
+# Makefile for arch-dependent kernel code
+.include <minix.own.mk>
+
+.PATH: ${.CURDIR}/arch/${ARCH}
+SRCS+= arch_do_vmctl.c \
+ breakpoints.c \
+ arch_clock.c \
+ debugreg.S \
+ do_int86.c \
+ do_iopenable.c \
+ do_readbios.c \
+ do_sdevio.c \
+ exception.c \
+ i8259.c \
+ klib.S \
+ memory.c \
+ protect.c \
+ arch_system.c \
+ apic.c \
+ apic_asm.S \
+ arch_watchdog.c
/*
* APIC handling routines. APIC is a requirement for SMP
*/
-#include "../../kernel.h"
+#include "kernel/kernel.h"
#include <unistd.h>
#include <minix/portio.h>
#include <minix/syslib.h>
-#include "../../proc.h"
-#include "../..//glo.h"
+#include "kernel/proc.h"
+#include "kernel/glo.h"
#include "proto.h"
#include <minix/u64.h>
#include "apic.h"
#include "apic_asm.h"
-#include "../../clock.h"
+#include "kernel/clock.h"
#include "glo.h"
#ifdef CONFIG_WATCHDOG
-#include "../../watchdog.h"
+#include "kernel/watchdog.h"
#endif
#define IA32_APIC_BASE 0x1b
#ifndef __ASSEMBLY__
-#include "../../kernel.h"
+#include "kernel/kernel.h"
EXTERN int ioapic_enabled;
EXTERN vir_bytes lapic_addr;
#ifndef __ASSEMBLY__
-#include "../../kernel.h"
+#include "kernel/kernel.h"
_PROTOTYPE( void apic_hwint00, (void) );
_PROTOTYPE( void apic_hwint01, (void) );
#include <machine/ports.h>
#include <minix/portio.h>
-#include "../../kernel.h"
+#include "kernel/kernel.h"
-#include "../../clock.h"
-#include "../../proc.h"
+#include "kernel/clock.h"
+#include "kernel/proc.h"
#include <minix/u64.h>
* SVMCTL_VALUE to this value
*/
-#include "../../system.h"
+#include "kernel/system.h"
#include <minix/type.h>
#include "proto.h"
/* system dependent functions for use inside the whole kernel. */
-#include "../../kernel.h"
+#include "kernel/kernel.h"
#include <unistd.h>
#include <ctype.h>
#include "archconst.h"
#include "proto.h"
-#include "../../proc.h"
-#include "../../debug.h"
+#include "kernel/proc.h"
+#include "kernel/debug.h"
#ifdef CONFIG_APIC
#include "apic.h"
-#include "../../kernel.h"
-#include "../../watchdog.h"
+#include "kernel/kernel.h"
+#include "kernel/watchdog.h"
#include "proto.h"
#include <minix/minlib.h>
-#include "../../kernel.h"
+#include "kernel/kernel.h"
#include "proto.h"
#include "debugreg.h"
* m1_p1: INT86_REG86
*/
-#include "../../system.h"
+#include "kernel/system.h"
#include <minix/type.h>
#include <minix/endpoint.h>
#include <machine/int86.h>
* Jorrit N. Herder <jnherder@cs.vu.nl>
*/
-#include "../../system.h"
-#include "../../kernel.h"
+#include "kernel/system.h"
+#include "kernel/kernel.h"
#include <minix/endpoint.h>
#include "proto.h"
* m2_p1: RDB_BUF buffer address in requesting process
*/
-#include "../../system.h"
+#include "kernel/system.h"
#include <minix/type.h>
/*===========================================================================*
* m2_i1: DIO_OFFSET (offset into the grant)
*/
-#include "../../system.h"
+#include "kernel/system.h"
#include <minix/devio.h>
#include <minix/endpoint.h>
* a panic.
*/
-#include "../../kernel.h"
+#include "kernel/kernel.h"
#include "proto.h"
#include <signal.h>
#include <string.h>
#include <assert.h>
-#include "../../proc.h"
-#include "../../proto.h"
+#include "kernel/proc.h"
+#include "kernel/proto.h"
extern int catch_pagefaults;
* intr_init: initialize the interrupt controller(s)
*/
-#include "../../kernel.h"
-#include "../../proc.h"
+#include "kernel/kernel.h"
+#include "kernel/proc.h"
#include "proto.h"
#include <minix/portio.h>
#include <machine/cpu.h>
#ifndef __I386_WATCHDOG_H__
#define __I386_WATCHDOG_H__
-#include "../../kernel.h"
+#include "kernel/kernel.h"
struct nmi_frame {
reg_t eax;
#ifndef __HW_INTR_X86_H__
#define __HW_INTR_X86_H__
-#include "../..//kernel.h"
+#include "kernel/kernel.h"
/* legacy PIC */
#include <minix/const.h>
#include <machine/interrupt.h>
#include "archconst.h"
-#include "../../const.h"
+#include "kernel/const.h"
#include "sconst.h"
/*
-#include "../../kernel.h"
-#include "../../proc.h"
-#include "../../vm.h"
+#include "kernel/kernel.h"
+#include "kernel/proc.h"
+#include "kernel/vm.h"
#include <machine/vm.h>
#include <machine/vm.h>
#include "proto.h"
-#include "../../proto.h"
-#include "../../proto.h"
-#include "../../debug.h"
+#include "kernel/proto.h"
+#include "kernel/debug.h"
#ifdef CONFIG_APIC
#include "apic.h"
#ifdef CONFIG_WATCHDOG
-#include "../../watchdog.h"
+#include "kernel/watchdog.h"
#endif
#endif
/*
- * This file, mpx386.s, is included by mpx.s when Minix is compiled for
- * 32-bit Intel CPUs. The alternative mpx88.s is compiled for 16-bit CPUs.
- *
* This file is part of the lowest layer of the MINIX kernel. (The other part
* is "proc.c".) The lowest layer does process switching and message handling.
* Furthermore it contains the assembler startup code for Minix and the 32-bit
* and modified by the boot monitor before the kernel starts.
*/
-#include "../../kernel.h" /* configures the kernel */
+#include "kernel/kernel.h" /* configures the kernel */
/* sections */
#include <minix/com.h>
#include <machine/interrupt.h>
#include "archconst.h"
-#include "../../const.h"
-#include "../../proc.h"
+#include "kernel/const.h"
+#include "kernel/proc.h"
#include "sconst.h"
/* Selected 386 tss offsets. */
* for local descriptors in the process table.
*/
-#include "../../kernel.h"
-#include "../../proc.h"
+#include "kernel/kernel.h"
+#include "kernel/proc.h"
#include "archconst.h"
#include "proto.h"
_PROTOTYPE(int breakpoint_set, (phys_bytes linaddr, int index, int flags));
/* functions defined in architecture-independent kernel source. */
-#include "../../proto.h"
+#include "kernel/proto.h"
#endif
#ifndef __SCONST_H__
#define __SCONST_H__
-#include "../../const.h"
+#include "kernel/const.h"
/* Miscellaneous constants used in assembler code. */
W = _WORD_SIZE /* Machine word size. */
#define __CLOCK_H__
#include "kernel.h"
-#include "arch/i386/clock.h"
+#include "arch_clock.h"
_PROTOTYPE(int boot_cpu_init_timer, (unsigned freq));
#include "kernel.h"
#include "proc.h"
#include "archconst.h"
-
-#include "arch/i386/hw_intr.h"
+#include "hw_intr.h"
/* number of lists of IRQ hooks, one list per supported line. */
PUBLIC irq_hook_t* irq_handlers[NR_IRQ_VECTORS] = {0};
+++ /dev/null
-# Makefile for system library implementation
-
-include /etc/make.conf
-
-# Directories
-u = /usr
-i = $u/include
-a = ../arch
-
-# Programs, flags, etc.
-#CC = exec cc $(CFLAGS) -c
-CC = exec cc
-#CCNOPROF = exec cc $(CFLAGSNOPROF) -c # no call profiling for these
-CPP = $l/cpp
-LD = $(CC) -.o
-CFLAGS = -I$i $(CPROFILE) -I$a/$(ARCH)/include
-#CFLAGSNOPROF = -I$i
-LDFLAGS = -i
-
-SYSTEM = ../system.a
-
-# What to make.
-all build install: $(SYSTEM)
-
-OBJECTS = \
- do_unused.o \
- do_fork.o \
- do_exec.o \
- do_newmap.o \
- do_clear.o \
- do_exit.o \
- do_trace.o \
- do_runctl.o \
- do_update.o \
- do_times.o \
- do_setalarm.o \
- do_stime.o \
- do_vtimer.o \
- do_irqctl.o \
- do_devio.o \
- do_vdevio.o \
- do_copy.o \
- do_umap.o \
- do_memset.o \
- do_setgrant.o \
- do_privctl.o \
- do_segctl.o \
- do_safecopy.o \
- do_safemap.o \
- do_sysctl.o \
- do_getksig.o \
- do_endksig.o \
- do_kill.o \
- do_sigsend.o \
- do_sigreturn.o \
- do_abort.o \
- do_getinfo.o \
- do_sprofile.o \
- do_cprofile.o \
- do_profbuf.o \
- do_vmctl.o \
- do_mcontext.o \
- do_schedule.o \
- do_schedctl.o
-
-build $(SYSTEM): $(SYSTEM)($(OBJECTS))
- aal cr $@ *.o
-# aal cr $@ $(OBJECTS)
-# ar cru $(.TARGET) $(.OODATE)
-
-clean:
- rm -f $(SYSTEM) *.o *~ *.bak
-
-depend:
- mkdep "$(CC) $(CFLAGS) -E" *.c > .depend
--- /dev/null
+# Makefile for system library implementation
+.include <minix.own.mk>
+
+.PATH: ${.CURDIR}/system
+SRCS+= \
+ do_unused.c \
+ do_fork.c \
+ do_exec.c \
+ do_newmap.c \
+ do_clear.c \
+ do_exit.c \
+ do_trace.c \
+ do_runctl.c \
+ do_update.c \
+ do_times.c \
+ do_setalarm.c \
+ do_stime.c \
+ do_vtimer.c \
+ do_irqctl.c \
+ do_devio.c \
+ do_vdevio.c \
+ do_copy.c \
+ do_umap.c \
+ do_memset.c \
+ do_setgrant.c \
+ do_privctl.c \
+ do_segctl.c \
+ do_safecopy.c \
+ do_safemap.c \
+ do_sysctl.c \
+ do_getksig.c \
+ do_endksig.c \
+ do_kill.c \
+ do_sigsend.c \
+ do_sigreturn.c \
+ do_abort.c \
+ do_getinfo.c \
+ do_sprofile.c \
+ do_cprofile.c \
+ do_profbuf.c \
+ do_vmctl.c \
+ do_mcontext.c \
+ do_schedule.c \
+ do_schedctl.c
* m1_p1: ABRT_MON_ADDR (virtual address of params)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <unistd.h>
#if USE_ABORT
* m1_i1: PR_ENDPT (endpoint of process to clean up)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* m5_l3: CP_NR_BYTES number of bytes to copy
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/type.h>
#if (USE_VIRCOPY || USE_PHYSCOPY)
* 14 Aug, 2006 Created (Rogier Meurs)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <string.h>
* m2_l2: DIO_VALUE (value to write/ return value read)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/devio.h>
#include <minix/endpoint.h>
#include <minix/portio.h>
* m2_i1: SIG_ENDPT # process for which PM is done
*/
-#include "../system.h"
+#include "kernel/system.h"
#if USE_ENDKSIG
* m1_p2: PR_NAME_PTR (pointer to program name)
* m1_p3: PR_IP_PTR (new instruction pointer)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <string.h>
#include <minix/endpoint.h>
* m_type: SYS_EXIT
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
#include <signal.h>
* m1_i3: PR_FORK_FLAGS (fork flags)
*/
-#include "../system.h"
-#include "../vm.h"
+#include "kernel/system.h"
+#include "kernel/vm.h"
#include <signal.h>
#include <string.h>
#include <assert.h>
#include <string.h>
#include <minix/endpoint.h>
-#include "../system.h"
+#include "kernel/system.h"
#if USE_GETINFO
* m2_l1: SIG_MAP # bit map with pending signals
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#include <minix/endpoint.h>
* ,, ,, (returns index of irq hook assigned at kernel)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* m2_i2: SIG_NUMBER # signal number to send to process
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#if USE_KILL
*
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <string.h>
#include <machine/mcontext.h>
* m2_l2: MEM_PATTERN (pattern byte to be written)
*/
-#include "../system.h"
+#include "kernel/system.h"
#if USE_MEMSET
* m1_i1: PR_ENDPT (install new map for this process)
* m1_p1: PR_MEM_PTR (pointer to the new memory map)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
#if USE_NEWMAP
* m1_i2: PR_PRIORITY the new priority
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <sys/resource.h>
#if USE_NICE
* m2_p1: CTL_ARG_PTR (pointer to request data)
*/
-#include "../system.h"
-#include "../ipc.h"
+#include "kernel/system.h"
+#include "kernel/ipc.h"
#include <signal.h>
#include <string.h>
#include <minix/endpoint.h>
* 14 Aug, 2006 Created (Rogier Meurs)
*/
-#include "../system.h"
+#include "kernel/system.h"
/*===========================================================================*
* do_profbuf *
* m1_i3: RC_FLAGS request flags
*/
-#include "../system.h"
+#include "kernel/system.h"
#if USE_RUNCTL
#include <minix/type.h>
#include <minix/safecopies.h>
-#include "../system.h"
+#include "kernel/system.h"
#define MAX_INDIRECT_DEPTH 5 /* up to how many indirect grants to follow? */
#include <minix/type.h>
#include <minix/safecopies.h>
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#include <sys/sigcontext.h>
#include <minix/endpoint.h>
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#include <sys/sigcontext.h>
#include <minix/endpoint.h>
* m4_l2: SEG_OFFSET (return offset within segment here)
* m4_l5: SEG_INDEX (return index into remote memory map here)
*/
-#include "../system.h"
+#include "kernel/system.h"
#if USE_SEGCTL
* m2_l1: ALRM_TIME_LEFT (return seconds left of previous)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* SG_SIZE number of entries
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/safecopies.h>
/*===========================================================================*
*
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <string.h>
#include <machine/cpu.h>
#include <sys/sigcontext.h>
*
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#include <string.h>
#include <sys/sigcontext.h>
* 14 Aug, 2006 Created (Rogier Meurs)
*/
-#include "../system.h"
+#include "kernel/system.h"
#if SPROFILE
* m4_l3: T_BOOTTIME
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* and then request-specific arguments in SYSCTL_ARG1 and SYSCTL_ARG2.
*/
-#include "../system.h"
+#include "kernel/system.h"
/*===========================================================================*
* m4_l5: T_BOOT_TICKS
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* m2_l2: CTL_DATA data to be written or returned here
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <sys/ptrace.h>
#if USE_TRACE
* m5_l3: CP_NR_BYTES (size of datastructure)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/endpoint.h>
* call may be unused when it is not defined or when it is disabled in the
* kernel's configuration.
*/
-#include "../system.h"
+#include "kernel/system.h"
/*===========================================================================*
* do_unused *
* m2_i2: SYS_UPD_DST_ENDPT (destination process endpoint)
*/
-#include "../system.h"
-#include "../ipc.h"
+#include "kernel/system.h"
+#include "kernel/ipc.h"
#include <string.h>
#if USE_UPDATE
* m2_i2: DIO_VEC_SIZE (number of ports to read or write)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <minix/devio.h>
#include <minix/endpoint.h>
#include <minix/portio.h>
* SVMCTL_VALUE to this value
*/
-#include "../system.h"
-#include "../vm.h"
-#include "../debug.h"
+#include "kernel/system.h"
+#include "kernel/vm.h"
+#include "kernel/debug.h"
#include <assert.h>
#include <minix/type.h>
* m2_l2: VT_ENDPT (process to which the timer belongs)
*/
-#include "../system.h"
+#include "kernel/system.h"
#include <signal.h>
#include <minix/endpoint.h>
#define __WATCHDOG_H__
#include "kernel.h"
-#include "arch/i386/watchdog.h"
+#include "arch_watchdog.h"
extern int watchdog_enabled; /* if set to non-zero the watch dog is enabled */
extern unsigned watchdog_local_timer_ticks; /* is timer still ticking? */
BINDIR?= /sbin
+CPPFLAGS.dmp_kernel.c+= -I${MINIXSRCDIR}
+CPPFLAGS.dmp_rs.c+= -I${MINIXSRCDIR}
+CPPFLAGS.dmp_vm.c+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
#include <minix/endpoint.h>
#include <minix/sysutil.h>
#include <minix/sys_config.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/debug.h"
-#include "../../kernel/type.h"
-#include "../../kernel/proc.h"
-#include "../../kernel/ipc.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/debug.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
+#include "kernel/ipc.h"
#define LINES 22
#include "inc.h"
#include <timers.h>
#include <minix/rs.h>
-#include "../../kernel/priv.h"
+#include "kernel/priv.h"
#include "../rs/const.h"
#include "../rs/type.h"
#include <sys/mman.h>
#include <minix/vm.h>
#include <timers.h>
-#include "../../kernel/proc.h"
+#include "kernel/proc.h"
#define LINES 24
BINDIR?= /usr/sbin
INSTALLFLAGS+= -S 32k
+CPPFLAGS.main.c+= -I${MINIXSRCDIR}
+CPPFLAGS.misc.c+= -I${MINIXSRCDIR}
+CPPFLAGS.schedule.c+= -I${MINIXSRCDIR}
+CPPFLAGS.utility.c+= -I${MINIXSRCDIR}
+
.include <minix.prog.mk>
#include "mproc.h"
#include "param.h"
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/proc.h"
#if ENABLE_SYSCALL_STATS
EXTERN unsigned long calls_stats[NCALLS];
#include <assert.h>
#include "mproc.h"
#include "param.h"
-#include "../../kernel/proc.h"
+#include "kernel/proc.h"
PUBLIC struct utsname uts_val = {
"Minix", /* system name */
#include <machine/archtypes.h>
#include <lib.h>
#include "mproc.h"
-#include "../../kernel/proc.h" /* for MIN_USER_Q */
+#include "kernel/proc.h" /* for MIN_USER_Q */
PRIVATE timer_t sched_timer;
#include <timers.h>
#include <string.h>
#include <machine/archtypes.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/type.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
#define munmap _munmap
#define munmap_text _munmap_text
BINDIR?= /usr/sbin
INSTALLFLAGS+= -S 850k
+CPPFLAGS= -I${MINIXSRCDIR}
+
SUBDIR= service
.include <minix.prog.mk>
#include <machine/archtypes.h>
#include <timers.h> /* For priv.h */
-#include "../../kernel/priv.h"
-#include "../../kernel/ipc.h"
+#include "kernel/priv.h"
+#include "kernel/ipc.h"
#include <stdlib.h>
#include <stdio.h>
#include <fcntl.h>
#include <a.out.h>
#include <minix/crtso.h>
-#include "../../kernel/const.h"
-#include "../../kernel/type.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
#include "../pm/mproc.h"
/* Declare some local functions. */
*/
#include "inc.h"
-#include "../../kernel/const.h"
-#include "../../kernel/type.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
EXTERN char *_brksize;
signal.c mmap.c slaballoc.c region.c pagefaults.c addravl.c \
physravl.c rs.c queryexit.c map_mem.c
-#Arch-specific sources
-.PATH: ${.CURDIR}/arch/${ARCH}
-SRCS+= vm.c pagetable.c arch_pagefaults.c util.S
-
DPADD+= ${LIBSYS}
LDADD+= -lsys
BINDIR?= /usr/sbin
CPPFLAGS+= -I${.CURDIR} -Iarch/${ARCH}
+CPPFLAGS+= -I${MINIXSRCDIR}
+.include "arch/${ARCH}/Makefile.inc"
.include <minix.prog.mk>
--- /dev/null
+.include <minix.own.mk>
+
+#Arch-specific sources
+.PATH: ${.CURDIR}/arch/${ARCH}
+SRCS+= vm.c pagetable.c arch_pagefaults.c util.S
extern int missing_spares;
#include <machine/archtypes.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/proc.h"
#include <signal.h>
incheck = 0; \
}
-#include "../../kernel/proc.h"
+#include "kernel/proc.h"
#define USE(obj, code) do { \
slabunlock(obj, sizeof(*obj)); \
#include "util.h"
#include <machine/archtypes.h>
-#include "../../kernel/const.h"
-#include "../../kernel/config.h"
-#include "../../kernel/type.h"
-#include "../../kernel/proc.h"
+#include "kernel/const.h"
+#include "kernel/config.h"
+#include "kernel/type.h"
+#include "kernel/proc.h"
/*===========================================================================*
* get_mem_map *