Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 2 years ago.
Improve this question
I know there have been similar questions but none of them seem to solve my problem. After successfully compiling my code, I got an "Access is denied." message from my command prompt after trying to run it (picture below).
The code I'm trying to run in a file named dummyC.c is:
#include <stdio.h>
int main (void) {
printf("Hello");
}
For context, I'm using Windows 10 64-bit. The GCC version (GCC -v) is MinGW 9.2.0, also in the attached picture. Is there any way I could solve this?
EDIT: The problem was my Avast antivirus flagging the output file a.exe as a Trojan or a virus. The problem was solved after I temporarily disabled all Avast shields.
I believe that your project is not in the correct place for the compiler to execute it, if it is on the desktop try to transfer it to a folder created in c:
Related
Closed. This question is not reproducible or was caused by typos. It is not currently accepting answers.
This question was caused by a typo or a problem that can no longer be reproduced. While similar questions may be on-topic here, this one was resolved in a way less likely to help future readers.
Closed 6 months ago.
Improve this question
I have a simple hello world program compiled by Mingw-w64. It works ok in cmd, but in powershell it just freeze and I get no output after running it.
#include <stdio.h>
int main(){
printf("Hello world\n");
}
I tried to copy the exe file to another computer. The powershell in the second computer can run the file, so it seems to be a local powershell setting problem. Anyone know what could cause the problem?
Follow up: I installed newer powershell 7 then it works. Still don't understand why the native powershell (version 5.1.19041.1320) doesn't work.
You wrote the slash incorrectly.
You wrote:
.\hi.exe
but you should have written:
./hi.exe
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 1 year ago.
Improve this question
I want to see how ping and ping6 work. I found this repository:
https://github.com/iputils/iputils
and it indeed has the source code I an interested. But every attempt to build results in this error:
C library 'cap' not found
I have searched for this library (libcap) on the internet without success. It does NOT appear to be included with pcap, as installing these packages failed to solve the problem:
apt-get install sqlite3 libsqlite3-dev libpcap0.8-dev
Any suggestions would be appreciated.
You need libcap, not libpcap. On Ubuntu, you probably need something like
# apt-get install libcap-dev
You'll also need meson and xsltproc.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
Closed 3 years ago.
Edit the question to include desired behavior, a specific problem or error, and the shortest code necessary to reproduce the problem. This will help others answer the question.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Improve this question
While compiling a C file in windows I get three files a .c file a .o file and a .exe file, now if i want to distribute my program I will give .exe file. But after compiling a .c in ubuntu I can't find the executable file which will run directly on other system by just clicking it.
The default file name is a.out, but you can specify another filename with gcc a.c -o my_executable.
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 4 years ago.
Improve this question
I have downloaded a .nsi file and now I have to launch this to get my missing Windows registry keys installed. I tried different things to open it but so far everything didnt work. Can anyone please tell me how to run this kind of files?
A .nsi file is an input to the process that creates an executable. You need the Nullsoft Scriptable Install System compiler: https://nsis.sourceforge.io/Download
More info: https://nsis.sourceforge.io/Simple_tutorials
Closed. This question does not meet Stack Overflow guidelines. It is not currently accepting answers.
This question does not appear to be about a specific programming problem, a software algorithm, or software tools primarily used by programmers. If you believe the question would be on-topic on another Stack Exchange site, you can leave a comment to explain where the question may be able to be answered.
Closed 8 years ago.
Improve this question
I'm trying to create a C program whose goal is to enable_irq and disable_irq.I have include linux/irq.h like that
#include <linux/irq.h>
And when I compile :
gcc myProgram.c -o myExecutable
I have the error : fatal error : linux/irq.h no file or folder find
What package I have to install? I'm on archLinux.
You cannot disable IRQs from a userspace application. Those functions are only available within the kernel.