Questions tagged [executable]

An executable is a binary file that can be executed by the operating system.

An executable is a binary file that can be executed by the operating system.

3697 questions
18
votes
2 answers

How to make gcc generate only machine code that can be loaded directly into memory and executed?

I would like to produce a file that I can load into memory (for example with mmap) and then jump to the start of that memory to run the code. Ideally, I'd like the option of either making the code relocatable (which might be inefficient) or…
David X
  • 3,998
  • 3
  • 29
  • 32
17
votes
19 answers

How to make a C++ EXE larger (artificially)

I want to make a dummy Win32 EXE file that is much larger than it should be. So by default a boiler plate Win32 EXE file is 80 KB. I want a 5 MB one for testing some other utilities. The first idea is to add a resource, but as it turns out embedded…
Phil
  • 231
  • 1
  • 3
  • 7
17
votes
1 answer

How does DOS load a program into memory?

What steps does MS-DOS take to load a COM or EXE file into memory? Are there still references online as to how this happens? The best I can think of is possibly referring to dosbox source.
Nick Sonneveld
  • 3,356
  • 6
  • 39
  • 48
17
votes
2 answers

Python - create an EXE that runs code as written, not as it was when compiled

I'm making a pygame program that is designed to be modular. I am building an exe with pygame2exe of the file main.py, which basically just imports the real main game and runs it. What I'm hoping for is a sort of launcher that will execute Python…
Matthew Fournier
  • 1,077
  • 2
  • 17
  • 32
17
votes
4 answers

Making an executable bash file run when clicked

I have a bash file that does some file manipulation. I don't want to have to open the terminal every time I run it. Is there a way to make the program run when I double click it? (Like a windows .exe file) Thanks
jamesatha
  • 7,280
  • 14
  • 37
  • 54
17
votes
9 answers

What languages allow cross-platform native executables to be created?

I'm frustrated to discover that Java lacks an acceptable solution for creating programs that will run via double-click. Other than .NET for Windows, what modern and high-level programming languages can I write code in that can be compiled for…
JT.
  • 171
  • 1
  • 4
17
votes
4 answers

Python equivalent of unix "strings" utility

I'm trying to write a script which will extract strings from an executable binary and save them in a file. Having this file be newline-separated isn't an option since the strings could have newlines themselves. This also means, however, that using…
joshlf
  • 21,822
  • 11
  • 69
  • 96
17
votes
1 answer

How do you compile an Erlang program into a standalone windows executable?

Richard of Last.fm over at metabrew has ported his apps to Erlang. It was also done by riak, couchdb and others. He mentions extracting the needed parts, or including the whole VM into the distribution. Main trait here is: the program does not…
Alex V.
  • 333
  • 2
  • 13
16
votes
13 answers

How to read / write .exe machine code manually?

I am not well acquainted to the compiler magic. The act of transforming human-readable code (or the not really readable Assembly instructions) into machine code is, for me, rocket science combined with sorcery. I will narrow down the subject of this…
Peter Perháč
  • 20,434
  • 21
  • 120
  • 152
16
votes
5 answers

How to embed a file into an executable file?

I have two problems, the first has been solved. Current problem If I embed a file that requires a library to load it, such as a jpeg image or a mp3 music, I will need to use the file as input to the library. However, each library is different and…
Squall
  • 4,344
  • 7
  • 37
  • 46
16
votes
1 answer

PyInstaller creates slow executable

I'm using PyInstaller to create a single executable of a python program using PyQt. It creates the .exe and runs fine, but takes between 15 to 20 seconds to start. I thought I could get by with creating a splash screen so the user would at least…
Stephen
  • 663
  • 5
  • 13
  • 24
16
votes
2 answers

Ubuntu recognizes executable as shared library and won't run it by clicking

I am first experiencing this issue on my fresh installation of lubuntu 17.04. I have used to use Ubuntu before and I hadn't this issue before. I compiled my qt application and I can execute it through command line by issuing with "./". However, I…
meetnick
  • 1,196
  • 2
  • 12
  • 28
16
votes
1 answer

Translation unit vs Compilation unit vs object file vs executable vs.... in C++

I couldn't find the difference between translation unit, compilation unit, object file, executable...At many places I've seen that one is used instead of other. I am aware that these files are generated during C++ program compilation and linkage.…
pasha
  • 2,035
  • 20
  • 34
16
votes
2 answers

How to read Mach-O header from object file?

I have spent the past few days experimenting with assembly, and now understand the relationship between assembly and machine code (using x86 via NASM on OSX, reading the Intel docs). Now I am trying to understand the details of how the linker works,…
Lance
  • 75,200
  • 93
  • 289
  • 503
16
votes
2 answers

How do I create a standalone exe with AutoHotkey?

I have created a script to remap the Windows Button to right-mouseclick. How can I create an executable AutoHotkey file that I can offer for download, that automatically runs only that script?
rubo77
  • 19,527
  • 31
  • 134
  • 226