Microsoft MVP성태의 닷넷 이야기
개발 환경 구성: 672. DosBox를 이용한 Turbo C, Windows 3.1 설치 [링크 복사], [링크+제목 복사],
조회: 12456
글쓴 사람
정성태 (techsharer at outlook.com)
홈페이지
첨부 파일
 

DosBox를 이용한 Turbo C, Windows 3.1 설치

DosBox를 다운로드해 설치하고,

DosBox
; https://www.dosbox.com/download.php?main=1

실행하면 5.0에 준하는 DOS 운영체제가 미리 설치된 화면이 하나 뜹니다. Z 드라이브가 매핑된 상태고 0 bytes free라서 할 수 있는 것이 없습니다. 대신 현재 윈도우 시스템의 특정 폴더를 마운팅할 수 있는데요, 따라서 C:\ 드라이브 역할을 할 수 있게 아무 디렉터리나 하나 만들어서 연결합니다.

Z:\> mount c c:\temp\cdrive
Drive C is mounted as local directory c:\temp\cdrive\

Z:\> c:

C:\> dir
Directory of C:\.
.       <DIR>       09-04-2023 9:51
..      <DIR>       09-04-2023 9:52
    0 File(s)               0 Bytes
    2 Dir(s)      262,111,744 Bytes Free.

물론 위의 설정은 다시 dosbox를 실행하면 없어집니다. 게다가 Z:\에 있는 autoexec.bat 파일은 동적으로 구성되는 것이며, Z: 드라이브의 모든 내용에 대해 변경이 허용되지 않습니다.

대신 Autoexec.bat에 대한 설정을 dosbox conf 파일에 할 수 있습니다. 제가 설치한 버전의 경우 다음의 경로에서 찾을 수 있었는데,

// DOSBox Status Window에 경로가 출력됩니다.

%USERPROFILE%\AppData\Local\DOSBox\dosbox-0.74-3.conf

이 파일을 편집해 (마지막에 있을) [autoexec] 섹션에 다음과 같이 추가합니다.

[autoexec]
# Lines in this section will be run at startup.
# You can put your MOUNT lines here.

mount c c:\temp\cdrive
C:\

그럼, DOSBox 실행 시마다 C:\ 드라이브에서 Prompt를 시작할 수 있습니다.




하는 김에 Turbo C도 설치해 볼까요? ^^ 방법은 지난 글에 설치한 것과 같습니다. "Borland Turbo C 2.01 (1989) (3.5-720k)" 파일의 압축을 풀어 나온 Compiler.img, Header.img, Install.img 3개 파일도 다시 압축을 푼 다음 아래와 같은 식으로 구성하고,

.\Install
         .\Compiler
         .\Header

위의 Install 디렉터리를 C:\ 드라이브로 매핑한 c:\temp\cdrive 디렉터리에 복사합니다. 일단, 복사만 하면 실행 중인 DOSBox에 해당 디렉터리가 곧바로 인식되지 않습니다. 물론 재시작하면 되지만, 그냥 Ctrl + F4 단축키를 눌러 재인식하는 것이 가능합니다.

이제 남은 작업은, .\Install\Install.exe 파일을 실행해 Turbo C를 설치하면 됩니다. 모두 설치한 이후에는 역시 dosbox conf 파일의 autoexec 섹션에 PATH 등을 연결하는 것도 잊지 마시고.

[autoexec]
# Lines in this section will be run at startup.
# You can put your MOUNT lines here.

mount c c:\temp\cdrive
PATH=C:\TC;Z:\
C:\




역시 이번에도 Windows 3.1을 설치해 볼까요? ^^ 구독자 다운로드 센터에서 구한 en_win311.exe을 실행해 압축을 푼 후, 그 디렉터리를 c:\temp\cdrive 하위에 복사합니다. Ctrl+F4로 재인식하고, 마운팅된 디렉터리에 setup.exe를 실행해 설치해 줍니다.

완료 후, 재부팅을 해야 하는데 마찬가지로 dosbox conf에 편의상 PATH를 하나 등록해 줍니다.

[autoexec]
# Lines in this section will be run at startup.
# You can put your MOUNT lines here.

mount c c:\temp\cdrive
PATH=C:\TC;C:\Windows;Z:\
C:\

이후, win.com을 실행하면 곧바로 Windows 3.1 화면으로 진입하는데요, 오호~~~ 윈도우 내에서 마우스도 잘 동작해 아래와 같이 ^^ 지뢰찾기 게임도 할 수 있습니다.

dosbox_1.png

3.1 정도의 무거운(?) 응용 프로그램을 정상적으로 호스팅할 정도면 제법 훌륭하게 도스 호환성을 구현한 것 같습니다.

참고로, 아래는 DOSBox에서의 단축키인데,

ALT-ENTER     Switch to full screen and back.
ALT-PAUSE     Pause emulation (hit ALT-PAUSE again to continue).
CTRL-F1       Start the keymapper.
CTRL-F4       Change between mounted floppy/CD images. Update directory cache for all drives.
CTRL-ALT-F5   Start/Stop creating a movie of the screen. (avi video capturing)
CTRL-F5       Save a screenshot. (PNG format)
CTRL-F6       Start/Stop recording sound output to a wave file.
CTRL-ALT-F7   Start/Stop recording of OPL commands. (DRO format)
CTRL-ALT-F8   Start/Stop the recording of raw MIDI commands.
CTRL-F7       Decrease frameskip.
CTRL-F8       Increase frameskip.
CTRL-F9       Kill DOSBox.
CTRL-F10      Capture/Release the mouse.
CTRL-F11      Slow down emulation (Decrease DOSBox Cycles).
CTRL-F12      Speed up emulation (Increase DOSBox Cycles)*.
ALT-F12       Unlock speed (turbo button/fast forward)**.
F11, ALT-F11  (machine=cga) change tint in NTSC output modes***
F11           (machine=hercules) cycle through amber, green, white colouring***

아마도 마우스와 전체 화면 정도 기능만 알아도 당장은 크게 불편함 없이 사용할 수 있을 것입니다.

이 외, 기타 도움말은 사이트에도 공개돼 있고,

Basic Setup and Installation of DosBox
; https://www.dosbox.com/wiki/Basic_Setup_and_Installation_of_DosBox

DOSBox v0.74-3 Manual
; https://www.dosbox.com/DOSBoxManual.html

"C:\Program Files (x86)\DOSBox-0.74-3\DOSBox 0.74-3 Manual.txt" 파일로도 제공됩니다.




[이 글에 대해서 여러분들과 의견을 공유하고 싶습니다. 틀리거나 미흡한 부분 또는 의문 사항이 있으시면 언제든 댓글 남겨주십시오.]







[최초 등록일: ]
[최종 수정일: 4/9/2023]

Creative Commons License
이 저작물은 크리에이티브 커먼즈 코리아 저작자표시-비영리-변경금지 2.0 대한민국 라이센스에 따라 이용하실 수 있습니다.
by SeongTae Jeong, mailto:techsharer at outlook.com

비밀번호

댓글 작성자
 



2024-09-04 08시16분
If Windows 3.11 required a 32-bit processor, why was it called a 16-bit operating system?
; https://devblogs.microsoft.com/oldnewthing/20100517-00/?p=14013

Why did Windows 95 setup use three operating systems?
; https://devblogs.microsoft.com/oldnewthing/20241112-00/?p=110507

Did the Windows 95 setup team forget that MS-DOS can do graphics?
; https://devblogs.microsoft.com/oldnewthing/20250211-00/?p=110862
정성태

1  2  3  4  5  6  7  8  9  [10]  11  12  13  14  15  ...
NoWriterDateCnt.TitleFile(s)
13693정성태7/24/20247244개발 환경 구성: 717. Visual Studio - C# 프로젝트에서 레지스트리에 등록하지 않은 COM 개체 참조 및 사용 방법파일 다운로드1
13692정성태7/24/20248026디버깅 기술: 199. Windbg - 리눅스에서 뜬 닷넷 응용 프로그램 덤프 파일에 포함된 DLL의 Export Directory 탐색
13691정성태7/23/20247385디버깅 기술: 198. Windbg - 스레드의 Win32 Message Queue 정보 조회
13690정성태7/23/20247019오류 유형: 919. Visual C++ 리눅스 프로젝트 - error : ‘u8’ was not declared in this scope
13689정성태7/22/20248524디버깅 기술: 197. Windbg - PE 포맷의 Export Directory 탐색
13688정성태7/21/20247630닷넷: 2281. C# - Lock / Wait 상태에서도 일부 Win32 메시지 처리파일 다운로드1
13687정성태7/19/20248060닷넷: 2280. C# - PostThreadMessage로 보낸 메시지를 Windows Forms에서 수신하는 방법파일 다운로드1
13686정성태7/19/20247855오류 유형: 918. Visual Studio - ATL Simple Object 추가 시 error C2065: 'IDR_...': undeclared identifier
13685정성태7/19/20248002스크립트: 66. Windows 디렉터리 경로를 WSL의 /mnt 포맷으로 구하는 방법 - 두 번째 이야기
13684정성태7/19/20248181닷넷: 2279. C# - 문자열 보간식 사례 (예: 조건 연산자 사용)
13683정성태7/18/20247651오류 유형: 917. ClrMD - Linux 환경의 .NET 5 덤프 분석 시 hang 현상
13682정성태7/18/20247869닷넷: 2278. WPF - 스레드에 종속되는 DependencyObject파일 다운로드1
13681정성태7/17/20247471닷넷: 2277. C# 13 - (2) 메서드 그룹의 자연 타입 개선 (메서드 추론 개선)파일 다운로드1
13680정성태7/16/20247857닷넷: 2276. C# - Method Group, Natural Type, function_type파일 다운로드1
13679정성태7/16/20246934Linux: 76. Linux - C++ (getaddrinfo 등을 담고 있는) libnss 정적 링크
13678정성태7/15/20247065VS.NET IDE: 191. Visual Studio 2022 - .NET 5 프로젝트를 Docker Support로 실행했을 때 오류
13677정성태7/15/20247155오류 유형: 916. MSBuild - CheckEolTargetFramework (warning NETSDK1138)
13676정성태7/14/20247327Linux: 75. gdb에서 glibc의 함수에 Breakpoint 걸기
13675정성태7/13/20249121C/C++: 166. C/C++ - DLL에서 template 함수를 export하는 방법 [1]파일 다운로드1
13674정성태7/13/20248003오류 유형: 915. Unhandled Exception: Microsoft.Diagnostics.NETCore.Client.ServerNotAvailableException: Unable to connect to Process
13673정성태7/11/20248442닷넷: 2275. C# 13 - (1) 신규 이스케이프 시퀀스 '\e'파일 다운로드1
13672정성태7/10/20247152닷넷: 2274. IIS - (프로세스 종료 없는) AppDomain Recycle
13671정성태7/10/20247261오류 유형: 914. Package ca-certificates is not installed.
13669정성태7/9/20247381오류 유형: 913. C# - AOT StaticExecutable 정적 링킹 시 빌드 오류
13668정성태7/8/20247398개발 환경 구성: 716. Hyper-V - Ubuntu 22.04 Generation 2 유형의 VM 설치
13667정성태7/7/20246621닷넷: 2273. C# - 리눅스 환경에서의 Hyper-V Socket 연동 (AF_VSOCK)파일 다운로드1
1  2  3  4  5  6  7  8  9  [10]  11  12  13  14  15  ...