Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 10-29-2010, 03:07 AM   #1
tank junior
Registered: Apr 2010
Posts: 42

Rep: Reputation: 0
ELF format (Self Extractable Executable) Creation


I am new to Linux. I did searched in forums but not able to find something useful. May be I didn't use the correct phrase.

Google is pointing me various article on this topic and nearest one that shows up is this one:

Unfortunately download is not available.

I would like to start with simple example:

1. Create a "Hello world" executable.
2. Attach files to it.
3. Add the code in in "Hello" executable to extract the files to a custom location.

1st is simple.

For second, above mentioned article suggest that CArchive can be created using Python. It means you can create a CArchive using "hello" executable and other files. How do you do that using Python?

For 3rd, I need more info about the implementation using C.


Old 10-29-2010, 04:18 AM   #2
Senior Member
Registered: Jan 2005
Location: Melbourne, Australia
Distribution: Debian Stretch (Fluxbox WM)
Posts: 1,389
Blog Entries: 52

Rep: Reputation: 357Reputation: 357Reputation: 357Reputation: 357
Self extracting executables on Linux are more typically done using a self extracting shell script. You can use a tool such as makeself to bundle one up.

If you want to manipulate ELF formats in C, then the libelf library is useful.
Old 10-29-2010, 05:23 PM   #3
LQ 5k Club
Registered: Sep 2009
Posts: 6,443
Blog Entries: 3

Rep: Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721Reputation: 721
Self-extracting executables are rare in Linux, they are mainly a Windows thing.

Linux typically uses packages, which are archives of the files plus some extra metadata, and they are installed using a special program called a package manager.


elf, python

Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - Hardware 1 05-11-2007 06:32 PM
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - General 1 05-11-2007 04:44 PM
Difference between Linux ELF Format and win32 ELF Format cmemo Linux - Software 1 05-11-2007 04:31 PM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 06:14 AM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration