0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?

More than 3 years have passed since last update.

OS自作環境をMacに作成する

Posted at

Macのバイナリー形式よりもELFのほうがなにかと楽なのでクロスコンパイル環境を構築します。

Dockerでクロスコンパイル環境をインストール

以下Dockerファイル

FROM ubuntu:latest
MAINTAINER username
WORKDIR /home/projects

RUN apt-get update && apt-get install -y \
  vim \
  gcc \
  g++ \
  binutils \
  build-essential

ビルド

docker run --rm -v $PWD:/home/projects 9665b0eb66db /bin/bash -c "cd /home/projects; make clean & make" |

QEmuをインストール

コンパイルしたファイルを実行するための仮想環境を構築します。

brew install qemu

これで環境準備が出来ました。

0
0
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
0
0

Delete article

Deleted articles cannot be recovered.

Draft of this article would be also deleted.

Are you sure you want to delete this article?