Questions tagged [crt]

For issues relating to utilizing the C runtime library.

The C runtime library is a special program library used by a compiler, to implement functions built into the C programming language, during the execution (runtime) of a computer program.

Not to be confused with CRT terminals.

364 questions
19
votes
4 answers

How to use .key and .crt file in java that generated by openssl?

I need asymmetric encryption in java. I generate .key and .crt files with own password and .crt file by openssl that said in http://www.imacat.idv.tw/tech/sslcerts.html . How to use these .key and .crt file to extract publickey and private key in…
Sajad Bahmani
  • 17,325
  • 27
  • 86
  • 108
18
votes
2 answers

Convert .crt file to .cer and .key

I was asked to help converting a certificate for a renewal. I was given the domainname.crt file along with some intermediate .crt files, but no .key file. They want me to convert the CRT to both a .CER and a .KEY file. I have looked at the following…
user1970778
  • 361
  • 2
  • 5
  • 10
17
votes
3 answers

How can I write a Windows application without using WinMain?

Windows GUI applications written in C/C++ have 'WinMain' as an entry point (rather than 'main'). My understanding of this is that the compiler generates a 'main' function to be called by the C Runtime. This 'main' function sets up the necessary…
Matthew Murdoch
  • 30,874
  • 30
  • 96
  • 127
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
3 answers

What functions does _WinMainCRTStartup perform?

This is part of a series of at least two closely related, but distinct questions. I hope I'm doing the right thing by asking them separately. I'm trying to get my Visual C++ 2008 app to work without the C Runtime Library. It's a Win32 GUI app…
Thomas
  • 174,939
  • 50
  • 355
  • 478
16
votes
5 answers

C++ - Memory leak testing with _CrtDumpMemoryLeaks() - Does not output line numbers

I'm working on a game with SDL in Visual Studio 2010. I came across the _CrtDumpMemoryLeaks() macro and thought I'd give it a go. Invoking _CrtDumpMemoryLeaks() does print memory leaks to the output window, but it does not show where it…
John
  • 2,571
  • 6
  • 32
  • 40
15
votes
4 answers

How to I update my C++ project in Visual Studio 2015 to use the new Universal CRT?

After VS2015 updated my project to the new Platform toolset v140, it fails to build due to a linker error : LNK1104 cannot open file 'libucrt.lib'. It appears this library has been moved around due to the new Universal CRT as mentioned in this…
Jesse Meyer
  • 315
  • 1
  • 3
  • 12
15
votes
1 answer

What is the difference between crtbegin.o, crtbeginT.o and crtbeginS.o?

I'm trying to link directly using ld to isolate a build problem. When I include /usr/lib/gcc/x86_64-linux-gnu/4.7/libstdc++.so, I get a few issues: ac-aaa.o: In function `__static_initialization_and_destruction_0': /usr/include/c++/4.7/iostream:75:…
jww
  • 97,681
  • 90
  • 411
  • 885
13
votes
2 answers

"getenv... function ... may be unsafe" - really?

I'm using MSVC to compile some C code which uses standard-library functions, such as getenv(), sprintf and others, with /W3 set for warnings. I'm told by MSVC that: 'getenv': This function or variable may be unsafe. Consider using _dupenv_s…
einpoklum
  • 118,144
  • 57
  • 340
  • 684
13
votes
2 answers

How to resolve crt0.o linking issue in cross compiling?

How to add ctr0.o ? I get this error: yagarto-4.7.2/bin/arm-none-eabi-ld: cannot find crt0.o: No such file or directory collect2: error: ld returned 1 exit status` while compiling very simple program from here: /* -- first.s */ /* This is a…
0x90
  • 39,472
  • 36
  • 165
  • 245
12
votes
2 answers

Verifying CRT used in library (.lib)

How do I check what runtime library a static library (.lib) in Windows has linked to? I'm compiling my project with /MDd and I presume a library I'm linking to is using /MTd Multi-threaded Debug Error 7 error LNK2005: "public: __thiscall…
Mohamed Bana
  • 1,251
  • 2
  • 17
  • 27
11
votes
6 answers

Using _crtBreakAlloc to find memory leaks - identifier "_crtBreakAlloc" is unidentified

I am trying to use _crtBreakAlloc in the Watch window as suggested in this link, but the value line says that 'identifier "_crtBreakAlloc" is unidentified' and it simply does not work. What am I doing wrong? I'm using Visual Studio by the way. An…
Sunspawn
  • 817
  • 1
  • 12
  • 27
11
votes
4 answers

How to install VC80CRT debug runtimes without full visual studio 2005?

I can't run a debug sdk application because it requires both VC 8 and VC 9 versions of the CRT. But it only requires visual studio 2008 for plugin dev, which is what I need. How do I install the debug runtimes from 2005 on to a Windows7 machine? I…
Ben L
  • 1,449
  • 1
  • 16
  • 32
11
votes
1 answer

check what run-time static library or dll uses

is there a tool in windows SDK to ckeck what CRT a library uses? for example I have a *.lib file, how do check if it's compiled with /MDd flag or /MT? also how to check the same for dll or exe? can this be done with dumpbin?
codekiddy
  • 5,897
  • 9
  • 50
  • 80
11
votes
4 answers

How to convert from UTF-8 to ANSI using standard c++

I have some strings read from the database, stored in a char* and in UTF-8 format (you know, "á" is encoded as 0xC3 0xA1). But, in order to write them to a file, I first need to convert them to ANSI (can't make the file in UTF-8 format... it's only…
1
2
3
24 25