Giter Club home page Giter Club logo

opbuild's Introduction

用于编译Lean源码的简易容器脚本

前置准备

系统要求

  1. 要求1core以上的处理器,至少2GB以上系统内存,2GB的swap空间;

  2. 要求40GB以上的磁盘空间,用于存放编译目录

  3. 必须使用支持Linux docker的操作系统

  4. 已经安装docker并能正常使用

使用方法

下载Dockerfile

git clone https://github.com/mm2231031/opbuild.git

生产镜像

cd opbuild
docker build --tag myopmake:latest ./

生成编译命令

# 指定编译存放路径
export OPDIR={youdir}

# 使用alias生成编译命令
cat >/etc/profile.d/opbuild.sh <<EOF
#!/bin/bash
alias opmake="docker run -it --rm -v $OPDIR:/opt/opbuild myopmake:latest /src/opbuild.sh "
EOF

# 重新载入环境变量
source /etc/profile

命令格式

# 升级/获取源码
opmake update

# 配置编译选项
opmake config

# 开始编译
opmake make

# 预下载dl包(不推荐)
opmake download

使用预先生成的docker镜像

下载docker镜像

docker pull jackmo233/opbuild

生成命令

# 指定源码存放路径
export OPDIR=/opt/youdir

# 生成命令
cat >/etc/profile.d/opbuild.sh <<EOF
#!/bin/bash
alias opmake="docker run -it --rm -v $OPDIR:/opt/opbuild jackmo233/opbuild:latest /src/opbuild.sh "
EOF

# 重新载入环境变量
source /etc/profile

opbuild's People

Contributors

mm2231031 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.