mirror of
https://github.com/drasko/codezero.git
synced 2026-01-22 15:53:16 +01:00
Removed hard coded values of toolchain and gcc cpu flags
This commit is contained in:
@@ -92,15 +92,18 @@ class LinuxContainerPacker:
|
||||
f.close()
|
||||
|
||||
def pack_container(self):
|
||||
# TODO: Need to sort this, we cannot call it in global space
|
||||
# as configuration file is not presnt in beginning
|
||||
config = configuration_retrieve()
|
||||
|
||||
self.generate_container_lds([self.kernel_image_in, \
|
||||
self.rootfs_elf_in, \
|
||||
self.atags_elf_in])
|
||||
self.generate_container_assembler([self.kernel_image_in, \
|
||||
self.rootfs_elf_in, \
|
||||
self.atags_elf_in])
|
||||
os.system("arm-none-linux-gnueabi-gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.container_elf_out, \
|
||||
self.container_lds_out,
|
||||
os.system(config.user_toolchain + "gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.container_elf_out, self.container_lds_out, \
|
||||
self.container_S_out))
|
||||
# Final file is returned so that the final packer needn't
|
||||
# get the packer object for this information
|
||||
@@ -156,11 +159,14 @@ class DefaultContainerPacker:
|
||||
f.close()
|
||||
|
||||
def pack_container(self):
|
||||
# TODO: Need to sort this, we cannot call it in global space
|
||||
# as configuration file is not presnt in beginning
|
||||
config = configuration_retrieve()
|
||||
|
||||
self.generate_container_lds(self.images_in)
|
||||
self.generate_container_assembler(self.images_in)
|
||||
os.system("arm-none-linux-gnueabi-gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.container_elf_out, \
|
||||
self.container_lds_out,
|
||||
os.system(config.user_toolchain + "gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.container_elf_out, self.container_lds_out, \
|
||||
self.container_S_out))
|
||||
# Final file is returned so that the final packer needn't
|
||||
# get the packer object for this information
|
||||
|
||||
@@ -16,7 +16,6 @@ sys.path.append(os.path.abspath(os.path.join(os.path.dirname(__file__), PROJRELR
|
||||
from config.projpaths import *
|
||||
from config.configuration import *
|
||||
|
||||
|
||||
containers_assembler_body = \
|
||||
'''
|
||||
.align 4
|
||||
@@ -78,11 +77,14 @@ class AllContainerPacker:
|
||||
f.write(file_body)
|
||||
|
||||
def pack_all(self):
|
||||
# TODO: Need to sort this, we cannot call it in global space
|
||||
# as configuration file is not presnt in beginning
|
||||
config = configuration_retrieve()
|
||||
|
||||
self.generate_container_lds(self.containers_lds_out)
|
||||
self.generate_container_S(self.containers_S_out)
|
||||
os.system("arm-none-linux-gnueabi-gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.containers_elf_out, \
|
||||
self.containers_lds_out,
|
||||
os.system(config.user_toolchain + "gcc " + "-nostdlib -o %s -T%s %s" \
|
||||
% (self.containers_elf_out, self.containers_lds_out, \
|
||||
self.containers_S_out))
|
||||
|
||||
# Return the final image to calling script
|
||||
|
||||
Reference in New Issue
Block a user