VOGONS


DOSBox ECE (for Windows & Linux)

Topic actions

Reply 1260 of 1550, by Dominus

User metadata
Rank DOSBox Moderator
Rank
DOSBox Moderator
kjliew wrote on 2021-01-24, 19:11:

GCC vs clang?

I can confirm that "<features.h>" exists on mingw-w64 GCC 10.2. Perhaps you could check out whatever latest GCC available from the homebrew. Or, you could remove the line "#include <features.h>" or simply touch a dummy "features.h" in the compiler's header files search path to see if anyone really use it. Sometimes, the symbols or declarations are already there in other included header files for a different compiler from GCC.

Indeed making a dummy features.h file worked.
I ran into other problems that were fixed by using an older Openglide version (when glext.h was still included with it) of CVS of about ten years ago 😉

Windows 3.1x guide for DOSBox
60 seconds guide to DOSBox
DOSBox SVN snapshot for macOS (10.4-11.x ppc/intel 32/64bit) notarized for gatekeeper

Reply 1261 of 1550, by Yesterplay80

User metadata
Rank Oldbie
Rank
Oldbie
Delfino Furioso wrote on 2021-01-28, 14:30:

Something must have gone wrong with the upload, unfortunately: all three r4425 archives show up as zero-bytes in size

Oops, thanks for pointing that out, indeed the upload must have failed miserably. Reuploaded the files!

My full-featured DOSBox SVN builds for Windows & Linux: Vanilla DOSBox and DOSBox ECE (Google Drive Mirror)

Reply 1263 of 1550, by Chuck

User metadata
Rank Newbie
Rank
Newbie

Hello to all, thanks for accepting me into the forum.
This is the first time i use compiling programs, and sorry if my english isn't perfect. I'm trying to compile DosBox ECE r4426 with MSYS2 64bit because i'd like to include MMX Patch, but i keep getting error during the "make" command. These are the command i use (in case i'm missing something, but i don't get any errors before the final command):
patch -p1 < mmx_20200624.diff
./autogen.sh
./configure
make
below there are the errors, the first one:

drive_fat.cpp: In constructor 'fatDrive::fatDrive(const char*, Bit32u, Bit32u, Bit32u, Bit32u, Bit32u)':
drive_fat.cpp:726:47: warning: taking address of packed member of 'partTable' may result in an unaligned pointer value [-Waddress-of-packed-member]
726 | mbrData.pentry[m].absSectStart = var_read(&mbrData.pentry[m].absSectStart);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:727:43: warning: taking address of packed member of 'partTable' may result in an unaligned pointer value [-Waddress-of-packed-member]
727 | mbrData.pentry[m].partSize = var_read(&mbrData.pentry[m].partSize);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:752:39: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
752 | bootbuffer.bytespersector = var_read(&bootbuffer.bytespersector);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:753:40: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
753 | bootbuffer.reservedsectors = var_read(&bootbuffer.reservedsectors);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:754:39: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
754 | bootbuffer.rootdirentries = var_read(&bootbuffer.rootdirentries);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:755:41: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
755 | bootbuffer.totalsectorcount = var_read(&bootbuffer.totalsectorcount);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:756:38: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
756 | bootbuffer.sectorsperfat = var_read(&bootbuffer.sectorsperfat);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:757:40: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
757 | bootbuffer.sectorspertrack = var_read(&bootbuffer.sectorspertrack);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:758:34: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
758 | bootbuffer.headcount = var_read(&bootbuffer.headcount);
| ^~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:759:42: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
759 | bootbuffer.hiddensectorcount = var_read(&bootbuffer.hiddensectorcount);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp:760:38: warning: taking address of packed member of 'bootstrap' may result in an unaligned pointer value [-Waddress-of-packed-member]
760 | bootbuffer.totalsecdword = var_read(&bootbuffer.totalsecdword);
| ^~~~~~~~~~~~~~~~~~~~~~~~~
drive_fat.cpp: In function 'void copyDirEntry(const direntry*, direntry*)':
drive_fat.cpp:1062:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1062 | var_write(&dst->crtTime, src->crtTime);
| ^~~~~~~~~~~~~
drive_fat.cpp:1063:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1063 | var_write(&dst->crtDate, src->crtDate);
| ^~~~~~~~~~~~~
drive_fat.cpp:1064:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1064 | var_write(&dst->accessDate, src->accessDate);
| ^~~~~~~~~~~~~~~~
drive_fat.cpp:1065:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1065 | var_write(&dst->hiFirstClust, src->hiFirstClust);
| ^~~~~~~~~~~~~~~~~~
drive_fat.cpp:1066:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1066 | var_write(&dst->modTime, src->modTime);
| ^~~~~~~~~~~~~
drive_fat.cpp:1067:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1067 | var_write(&dst->modDate, src->modDate);
| ^~~~~~~~~~~~~
drive_fat.cpp:1068:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1068 | var_write(&dst->loFirstClust, src->loFirstClust);
| ^~~~~~~~~~~~~~~~~~
drive_fat.cpp:1069:12: warning: taking address of packed member of 'direntry' may result in an unaligned pointer value [-Waddress-of-packed-member]
1069 | var_write(&dst->entrysize, src->entrysize);
| ^~~~~~~~~~~~~~~

and the other at the end:

midi_fluidsynth.h: In member function 'virtual void MidiHandler_fluidsynth::PlayMsg(Bit8u*)':
midi_fluidsynth.h:65:70: error: cast from 'Bit8u*' {aka 'unsigned char*'} to 'long int' loses precision [-fpermissive]
65 | LOG(LOG_MISC,LOG_WARN)("MIDI:fluidsynth: Unknown Command: %08lx", (long)msg);
| ^~~~~~~~~
make[3]: *** [Makefile:367: midi.o] Error 1
make[3]: Leaving directory '/home/Chuck/dosbox/src/gui'
make[2]: *** [Makefile:450: all-recursive] Error 1
make[2]: Leaving directory '/home/Chuck/dosbox/src'
make[1]: *** [Makefile:395: all-recursive] Error 1
make[1]: Leaving directory '/home/Chuck/dosbox'
make: *** [Makefile:336: all] Error 2

What am i doing wrong? Maybe i miss some packages?

Reply 1264 of 1550, by Dominus

User metadata
Rank DOSBox Moderator
Rank
DOSBox Moderator

At first glance it seems you need to install fluidsynth via Msys2's pacman.

Windows 3.1x guide for DOSBox
60 seconds guide to DOSBox
DOSBox SVN snapshot for macOS (10.4-11.x ppc/intel 32/64bit) notarized for gatekeeper

Reply 1266 of 1550, by jmarsh

User metadata
Rank Oldbie
Rank
Oldbie

Try

LOG(LOG_MISC,LOG_WARN)("MIDI:fluidsynth: Unknown Command: %p", msg);

instead.
Not sure how printing the pointer of the msg is going to reveal the unknown contents of it, but that's how it's coded...

Reply 1267 of 1550, by Chuck

User metadata
Rank Newbie
Rank
Newbie

Fluidsynth is installed.
I've tried MSYS2 32bit too, same result, should i try it on an x86 version of Windows?
The command gives me this message:

LOG(LOG_MISC,LOG_WARN)("MIDI:fluidsynth: Unknown Command: %p", msg);
bash: syntax error near unexpected token `LOG_MISC,LOG_WARN'

Reply 1268 of 1550, by Qbix

User metadata
Rank DOSBox Author
Rank
DOSBox Author

you can just remove that log message. Replace the line with ;

edit: i misread. The fix jmarsh proposed is editing the file that gives the error and changing it to that.
You are just "running" the fix. That is not what it is for.

Water flows down the stream
How to ask questions the smart way!

Reply 1269 of 1550, by Chuck

User metadata
Rank Newbie
Rank
Newbie

You mean the line contained into the file "midi.fluidsynth.h" with the error, right? If yes, now compiling stops sooner:

In file included from midi.cpp:75:
midi_fluidsynth.h: In member function 'virtual void MidiHandler_fluidsynth::PlayMsg(Bit8u*)':
midi_fluidsynth.h:65:70: error: no match for call to '(LOG) (const char [37], Bit8u*&)'
65 | LOG(LOG_MISC,LOG_WARN)("MIDI:fluidsynth: Unknown Command: %p", msg);
| ^
In file included from ../../include/dosbox.h:72,
from midi.cpp:27:
../../include/logging.h:64:7: note: candidate: 'void LOG::operator()(const char*)'
64 | void operator()(char const* ) { }
| ^~~~~~~~
../../include/logging.h:64:7: note: candidate expects 1 argument, 2 provided
../../include/logging.h:65:7: note: candidate: 'void LOG::operator()(const char*, double)'
65 | void operator()(char const* , double ) { }
| ^~~~~~~~
../../include/logging.h:65:32: note: no known conversion for argument 2 from 'Bit8u*' {aka 'unsigned char*'} to 'double'
65 | void operator()(char const* , double ) { }
| ^~~~~~
../../include/logging.h:66:7: note: candidate: 'void LOG::operator()(const char*, double, double)'
66 | void operator()(char const* , double , double ) { }
| ^~~~~~~~
../../include/logging.h:66:7: note: candidate expects 3 arguments, 2 provided
../../include/logging.h:67:7: note: candidate: 'void LOG::operator()(const char*, double, double, double)'
67 | void operator()(char const* , double , double , double ) { }
| ^~~~~~~~
../../include/logging.h:67:7: note: candidate expects 4 arguments, 2 provided
../../include/logging.h:68:7: note: candidate: 'void LOG::operator()(const char*, double, double, double, double)'
68 | void operator()(char const* , double , double , double , double ) { }
| ^~~~~~~~
../../include/logging.h:68:7: note: candidate expects 5 arguments, 2 provided
../../include/logging.h:69:7: note: candidate: 'void LOG::operator()(const char*, double, double, double, double, double)'
69 | void operator()(char const* , double , double , double , double , double ) { }
| ^~~~~~~~
../../include/logging.h:69:7: note: candidate expects 6 arguments, 2 provided
../../include/logging.h:70:7: note: candidate: 'void LOG::operator()(const char*, double, double, double, double, double, double)'
70 | void operator()(char const* , double , double , double , double , double , double ) { }
| ^~~~~~~~
../../include/logging.h:70:7: note: candidate expects 7 arguments, 2 provided
../../include/logging.h:71:7: note: candidate: 'void LOG::operator()(const char*, double, double, double, double, double, double, double)'
71 | void operator()(char const* , double , double , double , double , double , double , double) { }
| ^~~~~~~~
../../include/logging.h:71:7: note: candidate expects 8 arguments, 2 provided
../../include/logging.h:75:7: note: candidate: 'void LOG::operator()(const char*, const char*)' (near match)
75 | void operator()(char const* , char const* ) { }
| ^~~~~~~~
../../include/logging.h:75:7: note: conversion of argument 2 would be ill-formed:
In file included from midi.cpp:75:
midi_fluidsynth.h:65:67: error: invalid conversion from 'Bit8u*' {aka 'unsigned char*'} to 'const char*' [-fpermissive]
65 | LOG(LOG_MISC,LOG_WARN)("MIDI:fluidsynth: Unknown Command: %p", msg);
| ^~~
| |
| Bit8u* {aka unsigned char*}
In file included from ../../include/dosbox.h:72,
from midi.cpp:27:
../../include/logging.h:76:7: note: candidate: 'void LOG::operator()(const char*, const char*, double)'
76 | void operator()(char const* , char const* , double ) { }
| ^~~~~~~~
../../include/logging.h:76:7: note: candidate expects 3 arguments, 2 provided
../../include/logging.h:77:7: note: candidate: 'void LOG::operator()(const char*, const char*, double, double)'
77 | void operator()(char const* , char const* , double ,double ) { }
| ^~~~~~~~
Show last 29 lines
../../include/logging.h:77:7: note:   candidate expects 4 arguments, 2 provided
../../include/logging.h:78:7: note: candidate: 'void LOG::operator()(const char*, double, const char*)'
78 | void operator()(char const* , double , char const* ) { }
| ^~~~~~~~
../../include/logging.h:78:7: note: candidate expects 3 arguments, 2 provided
../../include/logging.h:79:7: note: candidate: 'void LOG::operator()(const char*, double, double, const char*)'
79 | void operator()(char const* , double , double, char const* ) { }
| ^~~~~~~~
../../include/logging.h:79:7: note: candidate expects 4 arguments, 2 provided
../../include/logging.h:80:7: note: candidate: 'void LOG::operator()(const char*, const char*, const char*)'
80 | void operator()(char const* , char const*, char const*) { }
| ^~~~~~~~
../../include/logging.h:80:7: note: candidate expects 3 arguments, 2 provided
../../include/logging.h:82:7: note: candidate: 'void LOG::operator()(const char*, double, double, double, const char*)'
82 | void operator()(char const* , double , double , double , char const* ) { }
| ^~~~~~~~
../../include/logging.h:82:7: note: candidate expects 5 arguments, 2 provided
../../include/logging.h:83:7: note: candidate: 'void LOG::operator()(const char*, double, const char*, double, double)'
83 | void operator()(char const* , double, char const*, double, double ) {}
| ^~~~~~~~
../../include/logging.h:83:7: note: candidate expects 5 arguments, 2 provided
make[3]: *** [Makefile:367: midi.o] Error 1
make[3]: Leaving directory '/home/Chuck/dosbox/src/gui'
make[2]: *** [Makefile:450: all-recursive] Error 1
make[2]: Leaving directory '/home/Chuck/dosbox/src'
make[1]: *** [Makefile:395: all-recursive] Error 1
make[1]: Leaving directory '/home/Chuck/dosbox'
make: *** [Makefile:336: all] Error 2

Reply 1270 of 1550, by Chuck

User metadata
Rank Newbie
Rank
Newbie

tried to replace the line with ";" too, and now complains about glide:

In file included from glide.cpp:23:
../../include/glide.h:64:10: fatal error: sdk2_glide.h: No such file or directory
64 | #include <sdk2_glide.h>
| ^~~~~~~~~~~~~~
compilation terminated.
make[4]: *** [Makefile:466: glide.o] Error 1
make[4]: Leaving directory '/home/Chuck/dosbox/src/hardware'
make[3]: *** [Makefile:486: all-recursive] Error 1
make[3]: Leaving directory '/home/Chuck/dosbox/src/hardware'
make[2]: *** [Makefile:450: all-recursive] Error 1
make[2]: Leaving directory '/home/Chuck/dosbox/src'
make[1]: *** [Makefile:395: all-recursive] Error 1
make[1]: Leaving directory '/home/Chuck/dosbox'
make: *** [Makefile:336: all] Error 2

Reply 1271 of 1550, by almeath

User metadata
Rank Member
Rank
Member

This an update on my attempt to get ECE to build in macOS Mojave 10.14.6.

The last point I reported on this, I could not compile because of a missing file:

In file included from glide.cpp:23:
../../include/glide.h:64:10: fatal error: 'sdk2_glide.h' file not found
#include <sdk2_glide.h>

With some useful feedback from Dominus, I managed to get OpenGlide to compile using an older version from the Github repository dated 11 January 2018. This resulted in the following files being added to my system:

usr/local/include/glide.h
usr/local/include/openglide/sdk2_3dfx.h
usr/local/include/openglide/sdk2_glide.h
usr/local/include/openglide/sdk2_glidesys.h
usr/local/include/openglide/sdk2_glideutl.h
usr/local/include/openglide/sdk2_sst1vid.h
usr/local/include/openglide/sdk2_unix.h
usr/local/lib/libglide.so.2
usr/local/lib/libglide2x.0.dylib
usr/local/lib/libglide2x.a
usr/local/lib/libglide2x.dylib
usr/local/lib/libglide2x.la

I then went back to try compiling ECE using a fresh extract of the source code:

chmod +x autogen.sh
dos2unix autogen.sh
./autogen.sh
./configure CXXFLAGS="std=c++11"
CXXFLAGS="std=c++11" make

By the way, this time I could not get CXXFLAGS="-std=c++11-03" make to work, as the "-03" part was rejected with the following output:

error: invalid value 'c++11-03' in '-std=c++11-03' note: use 'c++98' or 'c++03' for 'ISO C++ 1998 with amendments' standard note […]
Show full quote

error: invalid value 'c++11-03' in '-std=c++11-03'
note: use 'c++98' or 'c++03' for 'ISO C++ 1998 with amendments' standard
note: use 'gnu++98' or 'gnu++03' for 'ISO C++ 1998 with amendments and GNU extensions' standard
note: use 'c++11' for 'ISO C++ 2011 with amendments' standard
note: use 'gnu++11' for 'ISO C++ 2011 with amendments and GNU extensions' standard
note: use 'c++14' for 'ISO C++ 2014 with amendments' standard
note: use 'gnu++14' for 'ISO C++ 2014 with amendments and GNU extensions' standard
note: use 'c++17' for 'ISO C++ 2017 with amendments' standard
note: use 'gnu++17' for 'ISO C++ 2017 with amendments and GNU extensions' standard
note: use 'c++2a' for 'Working draft for ISO C++ 2020' standard
note: use 'gnu++2a' for 'Working draft for ISO C++ 2020 with GNU extensions' standard

So I just proceeded to run make with CXX flags set to "std=c++11".

Anyway.. I now have another error on which I am seeking advice/feedback:

g++ -DHAVE_CONFIG_H -I. -I../..  -I../../include -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_THREAD_SAFE  -std=c++11 -mno-ms-bitfields  -MT glide.o -MD -MP -MF .deps/glide.Tpo -c -o glide.o glide.cpp
glide.cpp:165:21: error: no member named 'info' in 'SDL_SysWMinfo'
hwnd = (HostPt)wmi.info.x11.window;
~~~ ^
glide.cpp:390:15: warning: using the result of an assignment as a condition without parentheses [-Wparentheses]
while(pfile = readdir(pdir)) {
~~~~~~^~~~~~~~~~~~~~~
glide.cpp:390:15: note: place parentheses around the assignment to silence this warning
while(pfile = readdir(pdir)) {
^
( )
glide.cpp:390:15: note: use '==' to turn this assignment into an equality comparison
while(pfile = readdir(pdir)) {
^
==
glide.cpp:1017:63: warning: format specifies type 'int' but the argument has type 'Bitu' (aka 'unsigned long') [-Wformat]
LOG_MSG("Glide:Invalid buffer passed in grLfbLock (%d)", buffer);
~~ ^~~~~~
%lu
2 warnings and 1 error generated.
make[4]: *** [glide.o] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

DOSBox SVN for macOS (x86-64) - customized with Munt MT-32, Nuked OPL3, 3dfx Voodoo, Extra RAM, Large HD, and more.
https://github.com/almeath/DOSBox-SVN-64-bit-for-macOS

Reply 1273 of 1550, by almeath

User metadata
Rank Member
Rank
Member
zirkoni wrote on 2021-01-31, 08:49:

"-std=c++11" and "-03" are two different parameters. There should be a space between them:
CXXFLAGS="-std=c++11 -03"

Thanks, ./configure will still complete with that parameter, but if I then go onto run make (either just make by itself, or with CXXFLAGS="-std=c++11 -03" , I get the following error in the terminal:

g++ -DHAVE_CONFIG_H -I. -I../..  -I../../include -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_THREAD_SAFE  -std=c++11 -03 -mno-ms-bitfields  -MT callback.o -MD -MP -MF .deps/callback.Tpo -c -o callback.o callback.cpp
clang: error: unknown argument: '-03'
make[4]: *** [callback.o] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

DOSBox SVN for macOS (x86-64) - customized with Munt MT-32, Nuked OPL3, 3dfx Voodoo, Extra RAM, Large HD, and more.
https://github.com/almeath/DOSBox-SVN-64-bit-for-macOS

Reply 1274 of 1550, by mr.cat

User metadata
Rank Member
Rank
Member
almeath wrote on 2021-01-31, 09:20:
Thanks, ./configure will still complete with that parameter, but if I then go onto run make (either just make by itself, or with […]
Show full quote
zirkoni wrote on 2021-01-31, 08:49:

"-std=c++11" and "-03" are two different parameters. There should be a space between them:
CXXFLAGS="-std=c++11 -03"

Thanks, ./configure will still complete with that parameter, but if I then go onto run make (either just make by itself, or with CXXFLAGS="-std=c++11 -03" , I get the following error in the terminal:

g++ -DHAVE_CONFIG_H -I. -I../..  -I../../include -I/usr/local/include/SDL -D_GNU_SOURCE=1 -D_THREAD_SAFE  -std=c++11 -03 -mno-ms-bitfields  -MT callback.o -MD -MP -MF .deps/callback.Tpo -c -o callback.o callback.cpp
clang: error: unknown argument: '-03'
make[4]: *** [callback.o] Error 1
make[3]: *** [all-recursive] Error 1
make[2]: *** [all-recursive] Error 1
make[1]: *** [all-recursive] Error 1
make: *** [all] Error 2

Looks like a typo, you have the -O3 switch written with zero, rather than with the upcase letter O

Reply 1275 of 1550, by almeath

User metadata
Rank Member
Rank
Member
mr.cat wrote on 2021-01-31, 09:42:

Looks like a typo, you have the -O3 switch written with zero, rather than with the upcase letter O

Thanks, fixed now.

I am now just dealing with the error detailed above:

glide.cpp:165:21: error: no member named 'info' in 'SDL_SysWMinfo'
hwnd = (HostPt)wmi.info.x11.window;

DOSBox SVN for macOS (x86-64) - customized with Munt MT-32, Nuked OPL3, 3dfx Voodoo, Extra RAM, Large HD, and more.
https://github.com/almeath/DOSBox-SVN-64-bit-for-macOS

Reply 1276 of 1550, by Chuck

User metadata
Rank Newbie
Rank
Newbie

About compiling DosBox ECE with MMX patch: i've been able to solve mt32emu errors thanks to the previous comments, and the glide one too (i've taken the required files from openglide and moved into include folder, hoping i've not done it wrong but now compliation continues), but now a new error shown, at this point could be some corrupted packages that casuses errors, but i'm a complete compiling newbie so i cannot know, anyway that's it:

make[3]: Entering directory '/home/Chuck/dosbox/src'
g++ -g -O2 -mno-ms-bitfields -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 libs/decoders/libdecoders.a libs/decoders/internal/lib/libopusfile.a libs/decoders/internal/lib/libspeexdsp.a libs/decoders/internal/lib/libopus.a libs/decoders/internal/lib/libogg.a -LD:/Giochi/Msys2/mingw64/lib -lmingw32 -lSDLmain -lSDL -mwindows -lpng -lz -lSDL_net -lfluidsynth -lopengl32 -lwinmm -lshlwapi -lws2_32 -lmt32emu
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(bands.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(PLC.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(decode_core.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
collect2.exe: error: ld returned 1 exit status
make[3]: *** [Makefile:413: dosbox.exe] Error 1
make[3]: Leaving directory '/home/Chuck/dosbox/src'
make[2]: *** [Makefile:450: all-recursive] Error 1
make[2]: Leaving directory '/home/Chuck/dosbox/src'
make[1]: *** [Makefile:395: all-recursive] Error 1
make[1]: Leaving directory '/home/Chuck/dosbox'
make: *** [Makefile:336: all] Error 2

Reply 1277 of 1550, by mr.cat

User metadata
Rank Member
Rank
Member
almeath wrote on 2021-01-31, 10:23:
Thanks, fixed now. […]
Show full quote
mr.cat wrote on 2021-01-31, 09:42:

Looks like a typo, you have the -O3 switch written with zero, rather than with the upcase letter O

Thanks, fixed now.

I am now just dealing with the error detailed above:

glide.cpp:165:21: error: no member named 'info' in 'SDL_SysWMinfo'
hwnd = (HostPt)wmi.info.x11.window;

Your libSDL situation is unclear to me...are you using SDL 1.x or 2.0?
(I guess the -I/usr/local/include/SDL switch suggests 1.x?)
If you compiled SDL yourself, it might be worthwhile to check config.log to see what backends were compiled in. X11 missing altogether maybe?

Reply 1278 of 1550, by mr.cat

User metadata
Rank Member
Rank
Member
Chuck wrote on 2021-01-31, 13:26:
About compiling DosBox ECE with MMX patch: i've been able to solve mt32emu errors thanks to the previous comments, and the glide […]
Show full quote

About compiling DosBox ECE with MMX patch: i've been able to solve mt32emu errors thanks to the previous comments, and the glide one too (i've taken the required files from openglide and moved into include folder, hoping i've not done it wrong but now compliation continues), but now a new error shown, at this point could be some corrupted packages that casuses errors, but i'm a complete compiling newbie so i cannot know, anyway that's it:

make[3]: Entering directory '/home/Chuck/dosbox/src'
g++ -g -O2 -mno-ms-bitfields -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 libs/decoders/libdecoders.a libs/decoders/internal/lib/libopusfile.a libs/decoders/internal/lib/libspeexdsp.a libs/decoders/internal/lib/libopus.a libs/decoders/internal/lib/libogg.a -LD:/Giochi/Msys2/mingw64/lib -lmingw32 -lSDLmain -lSDL -mwindows -lpng -lz -lSDL_net -lfluidsynth -lopengl32 -lwinmm -lshlwapi -lws2_32 -lmt32emu
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(bands.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(PLC.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
D:/Giochi/Msys2/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/ld.exe: libs/decoders/internal/lib/libopus.a(decode_core.o): in function `memcpy':
D:/Giochi/Msys2/mingw64/x86_64-w64-mingw32/include/string.h:202: undefined reference to `__memcpy_chk'
collect2.exe: error: ld returned 1 exit status
make[3]: *** [Makefile:413: dosbox.exe] Error 1
make[3]: Leaving directory '/home/Chuck/dosbox/src'
make[2]: *** [Makefile:450: all-recursive] Error 1
make[2]: Leaving directory '/home/Chuck/dosbox/src'
make[1]: *** [Makefile:395: all-recursive] Error 1
make[1]: Leaving directory '/home/Chuck/dosbox'
make: *** [Makefile:336: all] Error 2

A little bit of generic info...
The linking stage fails because it doesn't know where to find __memcpy_chk (the libs are listed with the -l switch). But I don't think that there is any lib missing in your case:
It seems __memcpy_chk is a version of memcpy() with buffer overflow checking that is used if a library is compiled with the switch -D_FORTIFY_SOURCE=2.
So that raises the question where did that libopus come from? EDIT: The libopus library is fetched automatically, so should be ok.

You could try recompiling libopus with CFLAGS="I=/usr/local/llsp", I've seen that mentioned as helping some.

EDIT: There's a linker flag you could try: -lssp
See here for more info:
https://github.com/msys2/MINGW-packages/issues/5868

Last edited by mr.cat on 2021-02-03, 19:39. Edited 1 time in total.

Reply 1279 of 1550, by almeath

User metadata
Rank Member
Rank
Member
mr.cat wrote on 2021-01-31, 14:51:

Your libSDL situation is unclear to me...are you using SDL 1.x or 2.0?
(I guess the -I/usr/local/include/SDL switch suggests 1.x?)
If you compiled SDL yourself, it might be worthwhile to check config.log to see what backends were compiled in. X11 missing altogether maybe?

I installed and upgraded SDL1 and 2 via Homebrew. I appear to have SDL1.25.15_3 and SDL2.0.14_1.

In usr/lib I have:

libSDL-1.2.0.dylib (alias of /usr/local/Cellar/sdl/1.2.15_3/lib/libSDL-1.2.0.dylib)
libSDL.a
libSDL.dylib (/usr/local/Cellar/sdl/1.2.15_3/lib/libSDL-1.2.0.dylib)
libSDL2-2.0.0.dylib (an alias of /usr/local/Cellar/sdl2/2.0.14_1/lib/libSDL2-2.0.0.dylib)
libSDL2.a
libSDL2.dylib (an alias of /usr/local/Cellar/sdl2/2.0.14_1/lib/libSDL2-2.0.0.dylib)
libSDL2main.a
libSDLmain.a

There is also an X11 folder in usr/lib, containing:

locale/common/ximcp.2.so
locale/common/ximcp.a
locale/common/ximcp.so
locale/common/xlcDef.2.so
locale/common/xlcDef.a
locale/common/xlcDef.so
locale/common/xlcUTF8Load.2.so
locale/common/xlcUTF8Load.a
locale/common/xlcUTF8Load.so
locale/common/xlibi18n.2.so
locale/common/xlibi18n.a
locale/common/xlibi18n.so
locale/common/xomGeneric.2.so
locale/common/xomGeneric.a
locale/common/xomGeneric.so

I also installed the XQuartz cask via Homebrew.

This is the full output from running

./configure CXXFLAGS="-std=c++11 -O3"
checking build system type... x86_64-apple-darwin18.7.0
checking host system type... x86_64-apple-darwin18.7.0
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make sets $(MAKE)... (cached) yes
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... no
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking whether gcc understands -c and -o together... yes
checking for style of include used by make... GNU
checking dependency style of gcc... gcc3
checking how to run the C preprocessor... gcc -E
checking for g++... g++
checking whether we are using the GNU C++ compiler... yes
checking whether g++ accepts -g... yes
checking dependency style of g++... gcc3
checking for ranlib... ranlib
checking for sdl-config... /usr/local/bin/sdl-config
checking for SDL - version >= 1.2.0... yes
checking SDL version only being 1.2.X... yes
checking for an ANSI C-conforming const... yes
checking for inline... inline
checking for grep that handles long lines and -e... /usr/bin/grep
checking for egrep... /usr/bin/grep -E
checking for ANSI C header files... yes
checking for sys/types.h... yes
checking for sys/stat.h... yes
checking for stdlib.h... yes
checking for string.h... yes
checking for memory.h... yes
checking for strings.h... yes
checking for inttypes.h... yes
checking for stdint.h... yes
checking for unistd.h... yes
checking for size_t... yes
checking whether struct tm is in sys/time.h or time.h... time.h
checking size of unsigned char... 1
checking size of unsigned short... 2
checking size of unsigned int... 4
checking size of unsigned long... 8
checking size of unsigned long long... 8
checking size of int *... 8
checking for stdlib.h... (cached) yes
checking for sys/types.h... (cached) yes
checking for sys/socket.h... yes
checking for netinet/in.h... yes
checking for pwd.h... yes
checking if environ can be included... no
checking if environ can be linked... yes
checking if dirent includes d_type... yes
Show last 96 lines
checking for powf in libm... yes
checking for library containing clock_gettime... none required
checking if compiler allows __attribute__... yes
checking if compiler allows __attribute__((always_inline)) ... yes
checking if compiler allows __attribute__((fastcall)) ... no
checking if compiler allows __builtin_expect... yes
checking if compiler supports -mno-ms-bitfields... yes
checking if compiler supports Apple's Core MIDI headers... yes
checking if compiler supports Apple's Core Audio headers... yes
checking for ALSA CFLAGS...
checking for ALSA LDFLAGS... -lasound -lm -ldl -lpthread
checking for libasound headers version >= 0.9.0... not present.
checking for snd_ctl_open in -lasound... no
checking whether byte ordering is bigendian... no
checking whether memory handling in the CPU Core will be inlined... yes
checking for target cpu type... x86-64 bit compatible
checking whether Apple user wants to override the build process to produce a 32 bit binary... no
checking whether x86 dynamic cpu core will be enabled... yes
checking whether recompiling cpu core will be enabled... no, using dynamic-x86
checking whether fpu emulation will be enabled... yes
checking whether the x86/x64 assembly fpu core will be enabled... yes
checking whether to enable unaligned memory access... yes
checking png.h usability... yes
checking png.h presence... yes
checking for png.h... yes
checking for png_get_io_ptr in -lpng... yes
checking whether screenshots will be enabled... yes
checking zlib.h usability... yes
checking zlib.h presence... yes
checking for zlib.h... yes
checking for compress in -lz... yes
checking whether recording will be enabled... yes
checking SDL_net.h usability... yes
checking SDL_net.h presence... yes
checking for SDL_net.h... yes
checking for SDLNet_Init in -lSDL_net... yes
checking for main in -lX11... yes
checking X11/XKBlib.h usability... yes
checking X11/XKBlib.h presence... yes
checking for X11/XKBlib.h... yes
checking for XKBlib support... yes
checking for new_fluid_synth in -lfluidsynth... yes
checking fluidsynth.h usability... yes
checking fluidsynth.h presence... yes
checking for fluidsynth.h... yes
checking for FluidSynth support... yes
checking wordexp.h usability... yes
checking wordexp.h presence... yes
checking for wordexp.h... yes
checking for main in -lGL... no
checking for main in -lopengl32... no
checking GL/gl.h usability... no
checking GL/gl.h presence... no
checking for GL/gl.h... no
checking whether opengl display output will be enabled... yes
checking ddraw.h usability... no
checking ddraw.h presence... no
checking for ddraw.h... no
checking whether ddraw display output will be enabled... no
checking sys/mman.h usability... yes
checking sys/mman.h presence... yes
checking for sys/mman.h... yes
checking for mprotect... yes
checking for realpath... yes
checking for setpriority support... no
checking that generated files are newer than configure... done
configure: creating ./config.status
config.status: creating Makefile
config.status: creating src/Makefile
config.status: creating src/cpu/Makefile
config.status: creating src/cpu/core_full/Makefile
config.status: creating src/cpu/core_normal/Makefile
config.status: creating src/cpu/core_dyn_x86/Makefile
config.status: creating src/cpu/core_dynrec/Makefile
config.status: creating src/debug/Makefile
config.status: creating src/dos/Makefile
config.status: creating src/fpu/Makefile
config.status: creating src/gui/Makefile
config.status: creating src/hardware/Makefile
config.status: creating src/hardware/mame/Makefile
config.status: creating src/hardware/serialport/Makefile
config.status: creating src/ints/Makefile
config.status: creating src/libs/Makefile
config.status: creating src/libs/zmbv/Makefile
config.status: creating src/libs/gui_tk/Makefile
config.status: creating src/libs/decoders/Makefile
config.status: creating src/misc/Makefile
config.status: creating src/shell/Makefile
config.status: creating src/platform/Makefile
config.status: creating src/platform/visualc/Makefile
config.status: creating visualc_net/Makefile
config.status: creating include/Makefile
config.status: creating docs/Makefile
config.status: creating config.h
config.status: config.h is unchanged
config.status: executing depfiles commands

DOSBox SVN for macOS (x86-64) - customized with Munt MT-32, Nuked OPL3, 3dfx Voodoo, Extra RAM, Large HD, and more.
https://github.com/almeath/DOSBox-SVN-64-bit-for-macOS