For easy develop pintos on macOS in CS302 OS 2019 Spring, SUSTech
You can get the code from your teacher or the stanford official website pintos.tar.gz and put the files like below.
.
├── Dockerfile
├── README.md
├── docker-compose.yml
├── docker-sync.yml
└── pintos
├── AUTHORS
├── LICENSE
└── src
$ gem install docker-sync
$ docker-compose build
$ docker-sync-stack start
Access http://localhost:5000! You can use gdb with GUI in browser! As shown in the screenshot below.
$ docker exec -it pintos-dev bash
From now on, you are in a docker container.
root@{CONTAINER-ID}:~/pintos/src# ls
devices examples filesys lib LICENSE Make.config Makefile Makefile.build Makefile.kernel Makefile.userprog misc tests threads userprog utils vm
root@{CONTAINER-ID}:~/pintos/src# cd threads
root@{CONTAINER-ID}:~/pintos/src/threads# make check
- You don't need to modify source code in this container. You can modify your code in host system.
- You have to compile source code in this container.
$ docker-sync-stack clean