Skip to content

ohwgiles/blobld

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commits
 
 
 
 
 
 

Repository files navigation

blobld

Create a 64bit ELF object from a file, with two symbols:

prefix_start: location of blob
  prefix_end: end of blob

Useful for embedding resources in an executable

Usage:

blobld [-s symbol_prefix] [-o output_file] input_file

This essentially replicates

(GNU) ld --format=binary input_file -o output_file

but more simply and less flexibly.

To access from C:

extern const char prefix_start[];
extern const char prefix_end[];

int main() {
	// returns size of blob
	return prefix_end - prefix_start;
}

Code is public domain

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published