성태의 닷넷 이야기
홈 주인
모아 놓은 자료
프로그래밍
질문/답변
사용자 관리
사용자
메뉴
아티클
외부 아티클
유용한 코드
온라인 기능
MathJax 입력기
최근 덧글
[정성태] Modules 창(Ctrl+Shift+U)을 띄워서, 해당 Op...
[정성태] 만드실 수 있습니다. 단지, Unity 엔진 내의 스크립트와 W...
[공진영] 안녕하세요 좋은글 감사합니다. 현재 제가 wpf로 관제 모...
[정성태] The Windows Registry Adventure #1: ...
[정성태] systemd for Developers I ; https:/...
[정성태] 엄밀히 object 타입의 인스턴스가 다른 타입으로 형변환 가능...
[정성태] 아래의 글에서 나오는 "Windows Application Pa...
[정성태] The history of calling conventions,...
[정성태] Secure and Deploy .NET Windows Form...
[정성태] Get Started with Milvus Vector DB i...
글쓰기
제목
이름
암호
전자우편
HTML
홈페이지
유형
제니퍼 .NET
닷넷
COM 개체 관련
스크립트
VC++
VS.NET IDE
Windows
Team Foundation Server
디버깅 기술
오류 유형
개발 환경 구성
웹
기타
Linux
Java
DDK
Math
Phone
Graphics
사물인터넷
부모글 보이기/감추기
내용
<div style='display: inline'> <h1 style='font-family: Malgun Gothic, Consolas; font-size: 20pt; color: #006699; text-align: center; font-weight: bold'>Visual Studio 2022로 빌드한 C++ 프로그램을 위한 다른 PC에서 실행하는 방법</h1> <p> 전에도 한번 설명했는데,<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > The program can't start because VCRUNTIME140.dll is missing from your computer. Try reinstalling the program to fix this problem. ; <a target='tab' href='https://www.sysnet.pe.kr/2/0/12512'>https://www.sysnet.pe.kr/2/0/12512</a> </pre> <br /> 첫 번째 메시지가 달라져서 다시 기록을 남깁니다. ^^<br /> <br /> <hr style='width: 50%' /><br /> <br /> Visual Studio 2022 환경에서 C++ 프로그램을 빌드한 경우,<br /> <br /> <img onclick='toggle_img(this)' class='imgView' alt='vcpp_2022_runtime_1.png' src='/SysWebRes/bbs/vcpp_2022_runtime_1.png' /><br /> <br /> 해당 EXE 파일을 다른 PC에 복사해 실행하면 이런 오류가 발생할 수 있습니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > ConsoleApplication1.exe - System Error The program can't start because ucrtbased.dll is missing from your computer. Try reinstalling the program to fix this problem. </pre> <br /> 왜냐하면, Visual C++ 런타임이 없기 때문인데요, 따라서 v143에 해당하는 런타임을 다음의 경로에서 구해,<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Redist\MSVC\v143 </pre> <br /> 대상 컴퓨터에 설치해 줘야 합니다.<br /> <br /> <hr style='width: 50%' /><br /> <br /> 그런데, 설치 후에도 여전히 동일한 실행 오류가 발생할 수 있습니다. 왜냐하면, 위의 메시지에 나온 ucrtbased.dll은 "d"가 붙은 debug 버전을 요구한다는 것이고, 따라서 여러분은 디버그 빌드한 exe 파일을 실행했기 때문입니다.<br /> <br /> 이런 경우 release 빌드한 exe 파일을 배포해 실행하면 되지만, 때로는 테스트를 위해 디버그 버전을 배포해야 하는 경우도 있으므로 그런 경우에는 다음의 2개 디렉터리에서 3개의 DLL을 디버그 빌드한 exe와 동일한 디렉터리에 복사하면 됩니다.<br /> <br /> <pre style='margin: 10px 0px 10px 10px; padding: 10px 0px 10px 10px; background-color: #fbedbb; overflow: auto; font-family: Consolas, Verdana;' > <span style='color: blue; font-weight: bold'>ucrtbased.dll</span> C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x64\ucrt\ <span style='color: blue; font-weight: bold'>ucrtbased.dll, vcruntime140d.dll</span> C:\Program Files\Microsoft Visual Studio\2022\Enterprise\VC\Redist\MSVC\14.32.31326\debug_nonredist\x64\Microsoft.VC143.DebugCRT </pre> </p><br /> <br /><hr /><span style='color: Maroon'>[이 글에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]</span> </div>
첨부파일
스팸 방지용 인증 번호
1927
(왼쪽의 숫자를 입력해야 합니다.)