Mirror of Harvey OS github repository http://harvey-os.org/

Keith Poole fb294cd955 Added sam into the build 8 سال پیش
386 122a5f8170 vga: move to using a 386 ureg struct 6 سال پیش
acme 5117dc9b78 Build the Acme tools. "acd" builds now but I don't have a machine with 6 سال پیش
adm 91d8c86336 Plan 9 from Bell Labs 2013-01-25 11 سال پیش
amd64 0f8a8be6de Add the syslinux mbr to amd64/bin 6 سال پیش
arm 999e4ebda0 ANOTHER round of type fixes. 9 سال پیش
cfg a5cd8682c5 add dhcp server and tftp server configs for harvey minicluster. 9 سال پیش
cron 4db2188a5b Plan 9 from Bell Labs 2007-10-06 17 سال پیش
dist 83d6593e6c Plan 9 from Bell Labs 2013-05-01 11 سال پیش
external_example e86fb5ff9c Add an example of how to build Harvey programs outside the Harvey tree 9 سال پیش
lib 0ab7bda4d3 outin now works. 6 سال پیش
mail 372adb5430 Plan 9 from Bell Labs 2010-01-17 15 سال پیش
mips 999e4ebda0 ANOTHER round of type fixes. 9 سال پیش
mnt 87ce7fe342 Fix profile and make directories to make drawterm/rio work. 6 سال پیش
power 999e4ebda0 ANOTHER round of type fixes. 9 سال پیش
power64 999e4ebda0 ANOTHER round of type fixes. 9 سال پیش
rc aa4621f522 APE is definitively gone from main tree. 6 سال پیش
sparc 999e4ebda0 ANOTHER round of type fixes. 9 سال پیش
sys fb294cd955 Added sam into the build 6 سال پیش
usr 1bf492b88e Improved version of memset 6 سال پیش
util 8297795876 Revert "build: added new build files" 6 سال پیش
web a2024e4ce0 I know you are doing this on purpose :) 6 سال پیش
.clang-format 94b4ad746a clang-format for all you gophers 6 سال پیش
.gitignore 8297795876 Revert "build: added new build files" 6 سال پیش
.gitmodules 4aaaec40f6 Switch to the ninep server from github.com/rminnich/ninep 6 سال پیش
AUTH_HOWTO e4c651fb2b Add auth bits 6 سال پیش
BUGLIST e23170fd6a Add a BUGLIST file 9 سال پیش
CONTRIBUTORS f2a2b35bee Add a CONTRIBUTORS file 6 سال پیش
LICENSE 25de748849 GNU General Public License 9 سال پیش
LICENSE.afpl 58309a73b6 Plan 9 from Bell Labs 2003-06-29 21 سال پیش
LICENSE.gpl 25de748849 GNU General Public License 9 سال پیش
NOTICE 25de748849 GNU General Public License 9 سال پیش
README 4aaaec40f6 Switch to the ninep server from github.com/rminnich/ninep 6 سال پیش
bootstrap.sh 222c737b2e Revert "Fixing bootstrap.sh" 6 سال پیش
build.json 0ad5b8e45a Reinstate (some) of the plan9 games 6 سال پیش
clean.json e3a9ca9dd2 clean: remove libs in clean rule 6 سال پیش
envsetup 843642b076 envsetup: set it up so that when you run envsetup it starts a shell 6 سال پیش
l 4761d30948 Simple script to enable remote console 9 سال پیش

README

This is Plan 9 for amd64 built with gcc (and soon, I hope, clang).

This file is a quick list of instructions to get you started quickly.


Prerequisites
=============

To build harvey and play with it, you need to have git, golang, qemu, gcc,
binutils and bison installed. On a Debian, Ubuntu or other .deb system,
you should be able to get going with

sudo aptitude install git golang build-essential bison qemu-system

If you are on a Mac, you should install macports (https://www.macports.org/) and do

port install x86_64-elf-gcc
port install x86_64-elf-binutils
port install qemu
export TOOLPREFIX=x86_64-elf-

or if you use homebrew (https://http://brew.sh/)

brew tap sevki/gcc_cross_compilers
brew install sevki/gcc_cross_compilers/x86_64-elf-gcc
brew install qemu go
export TOOLPREFIX=x86_64-elf-

GERRIT
======

We use gerrithub.io for code-review. If you want to submit changes, go to

https://review.gerrithub.io/#/admin/projects/Harvey-OS/harvey

and check out the repository from gerrithub rather than github. The clone
command will probably look something like this:

git clone ssh://USERNAME@review.gerrithub.io:29418/Harvey-OS/harvey

You'll need to bootstrap everything the first time:

./bootstrap.sh

This will set up the git repo for code review and build the `build` tool.
You should now be able to build everything by running

export ARCH=amd64
export PATH="$(pwd)/util:$PATH"
build all

Once building is complete, you can try booting the kernel with qemu

(cd sys/src/9/amd64 && sh ../../../../util/QRUN)

Next you should find a bug somewhere in harvey and fix it. In general, the
util/build tool "just works" in any subdirectory, so you can also build just
the stuff you are looking at, too, eg.

cd sys/src/cmd/aux
build aux.json

Let's say you found a bug and the files you needed to change were
sys/src/9/ip/tcp.c and sys/src/9/ip/ipaux.c. To submit this for review, you do

git add sys/src/9/ip/tcp.c
git add sys/src/9/ip/ipaux.c
git diff --staged # to check that the patch still makes sense
git commit -m 'your description of the patch'
git push

Note the lack of qualifiers in the last push command. It is important,
because it needs to be pushed to "origin HEAD:refs/for/master" for review
(and not to master). This will generate a code-review change request, others
will review it, and if it looks good we will merge it to the mainline repo
using gerrithub.io.

If your patch needs further work (you notice something wrong with it yourself,
or someone suggests changes), you can just edit the affected files and then
amend the change list as follows

git add sys/src/9/ip/tcp.c
git commit --amend
git push

More information on using Gerrit can be found on the gerrithub.io website.


Getting ninep to serve your files
================================

The currently recommended way of doing this is to run ninep/ufs as the
file server for harvey. It is provided as a submodule in util/third_party
and should be automatically compiled & copied to util/ when you run
'BUILD utils'.

Once it's built, you can run this:

(export HARVEY=$(pwd) && cd sys/src/9/amd64 && sh ../../../../util/GO9PRUN)

to boot with ufs serving the harvey directory for your harvey instance. Once
harvey is up, you can telnet onto it with

util/telnet localhost:5555

Where 5555 is forwarded to the harvey instance. This gives you a prompt
without any security. Once you have the prompt, you can mount the harvey
directory as your root like this (10.0.2.2 is what qemu has as the host)

srv tcp!10.0.2.2!5640 k
mount -a /srv/k /