Project

General

Profile

Feature #10605

loader: boot2 build should use ldscript

Added by Toomas Soome 8 months ago. Updated 7 months ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
bootloader
Start date:
2019-03-29
Due date:
% Done:

100%

Estimated time:
Difficulty:
Medium
Tags:

Description

The gptzfsboot and isoboot build depend on exact ordering of [entry] function and files and we need to be careful not to include extra code we do not want/need in boot2.

Simplify our life by using linker script to state the entry symbol and exclude linker sets. Entry function needs to be stored as very first function and we do not provide additional interactive commands. Also our fake multiboot structure needs to be at the beginning of the binary.

While there, clean up the Makefiles about {} constructs and build with -ffunction-sections -fdata-sections to make --gc-sections option to have chance to work.

History

#1

Updated by Toomas Soome 7 months ago

  • Description updated (diff)
#2

Updated by Electric Monk 7 months ago

  • Status changed from In Progress to Closed
  • % Done changed from 90 to 100

git commit e6b6ca04e8507fd588b555801518e701ceab9eeb

commit  e6b6ca04e8507fd588b555801518e701ceab9eeb
Author: Toomas Soome <tsoome@me.com>
Date:   2019-04-22T19:24:34.000Z

    10605 loader: boot2 build should use ldscript
    Reviewed by: Andy Fiddaman <andy@omniosce.org>
    Approved by: Dan McDonald <danmcd@joyent.com>

Also available in: Atom PDF