mirror of
https://github.com/drasko/codezero.git
synced 2026-01-12 10:53:16 +01:00
24 lines
715 B
Python
24 lines
715 B
Python
#
|
|
# Build script to autogenerate a bootdesc image
|
|
#
|
|
# Copyright (C) 2007 Bahadir Balban
|
|
#
|
|
import os, sys, shutil
|
|
from os.path import join
|
|
from scripts.config.config_invoke import *
|
|
|
|
config = configuration_retrieve()
|
|
builddir = ARGUMENTS.get('builddir', 'build/conts/posix')
|
|
|
|
env = Environment(CC = config.toolchain_userspace + 'gcc',
|
|
CCFLAGS = ['-g', '-nostdlib', '-ffreestanding', '-std=gnu99', '-Wall', '-Werror'],
|
|
LINKFLAGS = ['-nostdlib','-Tlinker.lds'],
|
|
ASFLAGS = ['-D__ASSEMBLY__'],
|
|
PROGSUFFIX = '.elf',
|
|
ENV = {'PATH' : os.environ['PATH']},
|
|
LIBS = 'gcc',
|
|
CPPPATH = '#include')
|
|
|
|
bootdesc = env.Program(join(builddir, 'bootdesc.elf'), join(builddir, 'bootdesc.c'))
|
|
Default(bootdesc)
|