Version 12 (modified by 18 years ago) ( diff ) | ,
---|
Bootstrapping steps:
- Modify env.sh to accept the uname output.
- Modify header.kmk to accept and correctly configure the platform / target OS.
- Run kBuild/env.sh to configure the kBuild environment.
- Copy unix like tools from you system to kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/. kBuild requires all ash (bash is ok), cat, cp, echo, install, ln, mkdir, mv, rm, rmdir and (gnu) sed. The kBuild copies must be prefixed with
kmk_
. These tools will be replaced later in the bootstrapping. - Configure and build GNU sed:
- Go to the src/sed directory.
- Run aclocal, autoconf and automake in src/sed if needed.
- Create and enter src/sed/obj.
- Run ../configure.
- Run make
- Copy config.h to src/sed/config.h.$BUILD_TARGET (or similar, see Makefile.kmk).
- Copy sed/sed[.exe] to kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/
- Configure and build plain GNU Make:
- Run aclocal, autoconf and automake in src/gmake if needed.
- Create and enter src/gmake/obj.
- Run ../configure.
- Run make
- Copy config.h to src/gmake/config.h.$BUILD_TARGET (or similar, see Makefile.kmk). Append empty string #defines for LOCALEDIR, LIBDIR, INCLUDEDIR and ALIASPATH (see config.h.linux).
- We've now got our own make binary which will be used further down.
- Build src/gmake using the GNU Make we just made:
- Go to the src/gmake directory.
- make -f Makefile.kmk
- When it breaks fix the compiler / linker error and redo the previous step.
- Copy out/$BUILD_TARGET.$BUILD_TARGET_ARCH/release/kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/ to kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/.
- Rebuild everything using kmk (which should now be in the path):
- Run kBuild/env.sh (or continue in the shell from the previous step).
- Go to the root.
- kmk BUILD_TYPE=release rebuild
- Fix build breaks and repeat the previous step.
- Copy out/$BUILD_TARGET.$BUILD_TARGET_ARCH/release/kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/ to kBuild/bin/$BUILD_TARGET.$BUILD_TARGET_ARCH/.
- Add and commit the changes (including the binaries).
Note! On GNU/Linux make sure you have a real yacc install. GNU bison is not sufficiently compatible with yacc to make src/ash (from NetBSD) happy.
Note:
See TracWiki
for help on using the wiki.