DOSBox Compilation Guides

General information and assistance with DOSBox.

Re: DOSBox Compilation Guides

Postby kjliew » 2019-7-19 @ 21:54

junglemontana wrote:g++ -g -O2 -mno-ms-bitfields -static-libgcc -static-libstdc++ -s -o dosbox.exe dosbox.o winres.o cpu/libcpu.a debug/libdebug.a dos/libdos.a fpu/libfpu.a hardware/libhardware.a gui/libgui.a ints/libints.a misc/libmisc.a shell/libshell.a hardware/mame/libmame.a hardware/serialport/libserial.a libs/gui_tk/libgui_tk.a -L/mingw32/lib -lmingw32 -lSDLmain -lSDL -mwindows -lncurses -lpng -lz -lSDL_net -lopengl32 -lwinmm -lws2_32

I noticed that on 2019-06-30, ncurses is back for mingw-w64 native code, but it didn't remove PDCurses which was its replacement when it was gone. I did a manual removal of PDCurses to get back to ncurses. My earlier patch is no longer valid. You were actually linking with ncurses while the undefined references were for PDCurses.

You need to pay attention to how your source was configured and if it picked ncurses or PDCurses. Typical, I would prefer ncurses over PDCurses, but I haven't tried my build, since I don't usually need the debugger from DOSBox. I am at r4252, too.
kjliew
Oldbie
 
Posts: 530
Joined: 2004-1-08 @ 03:03

Re: DOSBox Compilation Guides

Postby DosFreak » 2019-7-22 @ 20:48

So spent hours beating my head against a wall trying to get Windows 10 working using bhyve in FreeNAS. Looks like virtio is buggy so when you try to use it Windows crashes. AHCI works but the performance is so slow it's pretty much unuseable unless all you're going to do is surf the web and no video driver but the basic one...wtf?! and no gpu passthru support in FreeNAS. Works fine with Fedora imagine that.

Realized I only needed this particular VM for holding my the online store games and I can just use Linux for that so going to use Steam with Wine and Steam for Linux under bhyve to do those.

Since bhyve is buggy and clunky for Windows and I'd rather use one solution for all testing I'll start going through the guides with Vmware Workstation.
User avatar
DosFreak
l33t++
 
Posts: 10545
Joined: 2002-6-30 @ 16:35
Location: Your Head

Re: DOSBox Compilation Guides

Postby DosFreak » 2019-8-05 @ 02:30

Downloading VS2019 community now since I'm at the point of starting to setup the VMs for going back through the guides.

Found the below:

VS2017 w/ 98, NT4 and 2000
https://stackoverflow.com/questions/195 ... 6#53548116
https://tedwvc.wordpress.com/2010/11/07 ... dows-2000/


Investigate <XP on VS2017.
Investigate VS2019 with v141 toolset for XP. v142 Vista+
User avatar
DosFreak
l33t++
 
Posts: 10545
Joined: 2002-6-30 @ 16:35
Location: Your Head

Re: DOSBox Compilation Guides

Postby DosFreak » 2019-9-03 @ 14:11

Possible SDL2 Backports

Although in both cases possibly using a maximized window would be the easiest "fix".

Dual-Monitor
viewtopic.php?f=31&t=68955&p=782069#p782069

Dropped keys
viewtopic.php?f=31&t=66491

Compilation
viewtopic.php?f=32&t=69497&p=791252#p791089
User avatar
DosFreak
l33t++
 
Posts: 10545
Joined: 2002-6-30 @ 16:35
Location: Your Head

Re: DOSBox Compilation Guides

Postby junglemontana » 2019-9-08 @ 09:16

kjliew wrote:
junglemontana wrote:g++ -g -O2 -mno-ms-bitfields -static-libgcc -static-libstdc++ -s -o dosbox.exe dosbox.o winres.o cpu/libcpu.a debug/libdebug.a dos/libdos.a fpu/libfpu.a hardware/libhardware.a gui/libgui.a ints/libints.a misc/libmisc.a shell/libshell.a hardware/mame/libmame.a hardware/serialport/libserial.a libs/gui_tk/libgui_tk.a -L/mingw32/lib -lmingw32 -lSDLmain -lSDL -mwindows -lncurses -lpng -lz -lSDL_net -lopengl32 -lwinmm -lws2_32

I noticed that on 2019-06-30, ncurses is back for mingw-w64 native code, but it didn't remove PDCurses which was its replacement when it was gone. I did a manual removal of PDCurses to get back to ncurses. My earlier patch is no longer valid. You were actually linking with ncurses while the undefined references were for PDCurses.

You need to pay attention to how your source was configured and if it picked ncurses or PDCurses. Typical, I would prefer ncurses over PDCurses, but I haven't tried my build, since I don't usually need the debugger from DOSBox. I am at r4252, too.


Thanks. I found a solution:

I created a file curses.h in the main include directory of MSYS2/mingw with the following contents

Code: Select all
#include "ncurses/curses.h"


and now compiling was successful. Both 32-bit and 64-bit version seem to work well and the debugger appears correctly.



edit: Found a problem! Using Alt+X in the debugger window to set data view to DS:DX doesn't work. It enters an "x" into the debugger command line instead.
junglemontana
Newbie
 
Posts: 44
Joined: 2019-2-16 @ 17:37


Re: DOSBox Compilation Guides

Postby DosFreak » 2019-10-09 @ 20:33

VS2003 Windows 7+
http://bytepointer.com/articles/vs7.1_2 ... al_fix.htm

VS
mkdir c:\dosbox\vcpkg
cd c:\dosbox\vcpkg
git clone https://github.com/Microsoft/vcpkg
bootstrap-vcpkg
vcpkg integrate install
vcpkg install "library"

MT-32
https://www.gog.com/forum/general/dosbo ... lain/post6

C++98 for GCC
C++03 for VS

C++11 would probably bump the minimum VS requirement from VS 2003 to VS2012 or VS2013 and mabye GCC 4.8.1.

No loss of Windows OS compatibility when compiled with mingw w/ GCC but VS would be XP minimum due to the CRT breaking compatibility. Although I'm looking into that viewtopic.php?f=31&t=55706&p=792269&hilit=compilation#p792237

C++ 11 DOSBOX
viewtopic.php?f=32&t=69497&p=804131#p804131
User avatar
DosFreak
l33t++
 
Posts: 10545
Joined: 2002-6-30 @ 16:35
Location: Your Head

Previous

Return to DOSBox General

Who is online

Users browsing this forum: No registered users and 3 guests