Skip to content

Instantly share code, notes, and snippets.

@bradfa
Last active August 29, 2015 14:13
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save bradfa/4ad9162a6dfc1a8445f6 to your computer and use it in GitHub Desktop.
Save bradfa/4ad9162a6dfc1a8445f6 to your computer and use it in GitHub Desktop.
What's needed as prereqs for pkgsrc?

What's needed for pkgsrc?

What's pkgsrc?

pkgsrc has tons of buildable software which can be added to a core *nix system in order to do useful things.

Required Infrastructure

In order to create a toolchain, you need:

  • kernel
  • libc
  • binutils (which is in pkgsrc?)
  • gcc (hence gmp, mpfr, mpc [hence m4], elfutils?) (which is in pkgsrc?)
  • make (gmake in pkgsrc?)
  • shell tools (busybox?)

In order to get to a point where you can use pkgsrc, you need:

  • libstdc++
  • libncurses-devel
  • zlib
  • zlib-devel
  • openssl-devel (which is in pkgsrc?)

To get a usable modern gcc toolchain, you may also need:

  • patch (which is in pkgsrc? busybox patch may not work?)
  • gawk (which is in pkgsrc? will busybox awk work?)

To have a useful booted system, you may also need:

  • init system
  • bootloader (lilo?)

To build and use X things, you will also need:

  • x.org or similar (which is in pkgsrc?)

What should I do?

  1. Build a toolchain
  2. Setup directories
  3. Build and install musl, static busybox, Linux, bunch of config files, then boot into it to validate
  4. Build and install target toolchain (linux headers, binutils, gcc)
  5. Validate toolchain (build and run helloworld)
  6. Get pkgsrc working
  7. Write or kang scripts to rebuild musl, busybox, lilo, and toolchain
  8. Profit! (?)

What's not in pkgsrc that I might want?

  • lvm2 (for dm-crypt)
  • cryptsetup (for dm-crypt)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment