Code Monkey home page Code Monkey logo

oscomp-2k1000la-xv6's Introduction

OS大赛 - 内核设计loongarch赛道 - 俺争取不掉队

xv6-qemu-Loongarch-ls2k

俺争取不掉队设计的基于qemu-ls2k的os是基于xv6-ls3A5000修改而来的。

搭建开发环境

声明:本文档只适合在x86-64架构主机上搭建开发环境

  1. 克隆项目到本地。
  2. 打开顶层Makefile,更改TOOLPREFIX,这个是编译工具链的前缀,例如loongarch64-linux-gnu-gcc的前缀是loongarch64-linux-gnu-,请确保加上前缀后的gcc在本地是有效的命令。由于龙芯的工具链版本较多,且偶尔有兼容性问题,这里推荐使用大赛给出的工具链版本:大赛工具链,同时这个仓库里面有相应的gdb。
  3. 打开ls2k_debug.sh,更改qemu路径,qemu使用龙芯实验室提供的大赛qemu
  4. 使用make initdir初始化构建路径,每次新增模块都应执行这个命令。
  5. 使用make all构建项目。
  6. 执行ls2k_debug.sh运行,默认开启-s选项等待gdb接入调试。
  7. 使用vscode+gdb调试,请修改lanuch.json中的miDebuggerPath为你自己的gdb命令。

搭建开发环境可能遇到的问题

  1. 官方给出的交叉工具gdb是动态库版本,会有不明依赖,推荐使用Ubuntu 22.04
  2. 目前已知的依赖的包括: i. python请使用python3.10,或者将libpython3.10.so.1.0放入/lib/x86_64-linux-gnu/,重启主机。 ii. libstdc++.so.6以及libc.so.6可能不同版本不一样,尝试更新为最新版本。
  3. 其他依赖详见下图:

文档

oscomp-2k1000la-xv6's People

Contributors

lishuang-mk avatar hurryyyyyhug avatar homesamaranta avatar

Stargazers

 avatar SignKirigami avatar  avatar bigmagic123 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.