executable

Windows Lua to executable

心已入冬 提交于 2019-11-30 20:42:10
hi I have a Lua program (written in Lua 5.1). I'm on Windows 7, trying to convert it to an executable. No luck so far. I've read other posts here that suggested using srlua to do this so I've downloaded it but I'm on a loss as to what to do next. I installed cygwin as I understand it's necessary but I don't know how to use srlua to convert a lua file into an executable. Any help will be appreciated. Lorenzo Donati srlua is distributed as source only, so you have to compile it first (see this answer for suggestions on getting a free C compiler). BTW, Cygwin is not necessary at all. The

Store files in C# EXE file

て烟熏妆下的殇ゞ 提交于 2019-11-30 19:58:41
问题 It is actually useful for me to store some files in EXE to copy to selected location. I'm generating HTML and JS files and need to copy some CSS, JS and GIFs. Snippet System.IO.File.WriteAllBytes(@"C:\MyFile.bin", ProjectNamespace.Properties.Resources.MyFile); doesn't work for me! On "WriteAllBytes" it says: "cannot convert from 'System.Drawing.Bitmap' to 'byte[]'" for image and "cannot convert from 'string' to 'byte[]'" for text file. Help! UPDATE: Solved below. 回答1: Add the files you want

How can i execute an executable from memory?

邮差的信 提交于 2019-11-30 19:48:05
Let's say I have included a binary into my program during compilation so, I keep it in a variable something like var myExec =[]byte{'s','o','m','e',' ','b','y','t','e','s'} So my question is whether there is a way to execute this binary within my program without writing it back to the disc and calling exec or fork on it? I am writing my app in Golang so the method I am seeking for is to do it using Go or C (using CGO). Basically, I am seeking something like piping the bash script into bash just I don't know where can I pipe the bytes of a native executable to run it and writing it back to disk

Is it possible to produce stand alone haskell executable

萝らか妹 提交于 2019-11-30 19:22:30
Is there any way to produce stand alone haskell executable to run on different linux machines assuming the architecture is similar? Sorry I should have been clearer. The other machines might not have ghc installed on them - a bit like pyinstaller for python is what I was looking for? You can use the flags -static -optl-pthread -optl-static to avoid dynamically linked dependencies when compiling a Haskell project. This should help you run the compiled executable on two linux machines that do not have the exact same library versions. Yes it is possible. Just like with gcc-produced binaries, you

Dependency resolution in Linux

落爺英雄遲暮 提交于 2019-11-30 19:19:38
Under Windows I have used a program called dependency walker to examine the libraries the application is using. I was wondering how I can achieve this on Linux for a standard binary: ELF 32-bit LSB executable, Intel 80386, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.0, stripped Thanks. Try: ldd executable For example: [me@somebox ~]$ ldd /bin/ls linux-gate.so.1 => (0xb7f57000) librt.so.1 => /lib/tls/i686/cmov/librt.so.1 (0xb7f4c000) libselinux.so.1 => /lib/libselinux.so.1 (0xb7f32000) libacl.so.1 => /lib/libacl.so.1 (0xb7f2b000) libc.so.6 => /lib/tls/i686/cmov

using C# Process to run a Executable program

我怕爱的太早我们不能终老 提交于 2019-11-30 19:08:30
问题 I am a Bioinformatic person and I use C# for my work. I have been using Processes in C# to run Executable programs several times. This time I have a new issue. I have downloaded an exe file in Windows for a program named Blast(http://blast.ncbi.nlm.nih.gov/Blast.cgi?CMD=Web&PAGE_TYPE=BlastDocs&DOC_TYPE=Download). If I type in my command which is : blastp -query input.txt -db pdbaa -out output.txt it works fine. But when I copy paste the command from a notepad it will give an error. I searched

Error when building executable from Python3.6 script importing pandas using cx_Freeze

喜夏-厌秋 提交于 2019-11-30 17:48:20
问题 I'm trying to create a Python 3.6 executable using cx_Freeze which includes pandas and numpy. I'm using Python 3.6.5 and a virtual env created using virtualenvwrapper. I'm developing on Windows 10. cx_Freeze version is 5.1. Pandas versions is 0.23.4. My setup.py looks like this: import os from cx_Freeze import setup, Executable PYTHON_INSTALL_DIR = os.path.dirname(os.path.dirname(os.__file__)) os.environ['TCL_LIBRARY'] = os.path.join(PYTHON_INSTALL_DIR, 'tcl', 'tcl8.6') os.environ['TK_LIBRARY

Python deployment and /usr/bin/env portability

本秂侑毒 提交于 2019-11-30 17:38:47
At the beginning of all my executable Python scripts I put the shebang line: #!/usr/bin/env python I'm running these scripts on a system where env python yields a Python 2.2 environment. My scripts quickly fail because I have a manual check for a compatible Python version: if sys.version_info < (2, 4): raise ImportError("Cannot run with Python version < 2.4") I don't want to have to change the shebang line on every executable file, if it's possible; however, I don't have administrative access to the machine to change the result of env python and I don't want to force a particular version, as

How is code stored in the EXE format?

ⅰ亾dé卋堺 提交于 2019-11-30 17:15:09
问题 My questions are as follows: How does the Portable Executable format (on windows/unix) relate to the x86/x64 instruction set in general? Does the PE format store the exact set of opcodes supported by the processor, or is it a more generic format that the OS converts to match the CPU? How does the EXE file indicate the instruction set extensions needed (like 3DNOW! or SSE/MMX?) Are the opcodes common across all platforms like Windows, Mac and unix? Intel i386 compatible CPU chips like ones

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

99封情书 提交于 2019-11-30 15:14:17
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 can't execute it by clicking on file manager (neither PCManFM, Nautilus...) Both recognizes it as shared library file type. How can I run it by clicking directly on the file? this is what happens when I double-click the executable through file manager: build-log: 11:20:05: Running steps for project APP_release... 11:20:05: Configuration unchanged,