VOGONS


First post, by lucky7456969

User metadata
Rank Oldbie
Rank
Oldbie
Error	1	error C2198: 'SMPEG_new_rwops' : too few arguments for call	e:\jacky\downloads\dosbox\sdl_sound_visualc_srcs\sdl_sound\decoders\mp3.c	173	1	sdl_sound_dll

Thanks
Jack

Reply 1 of 12, by Dominus

User metadata
Rank DOSBox Moderator
Rank
DOSBox Moderator

Make sure you have every lib sdl_sound needs compiled and installed as well. In this case it looks like smpeg is missing perhaps.
I never succeeded with SDL_sound on Windows (but that was four years ago) while it isn't that hard on OS X...

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 2 of 12, by bloodbat

User metadata
Rank Oldbie
Rank
Oldbie

SDL_Sound needs a ton of external codecs you need to compile, so select what you want and discard what you don't, you need to satisfy dependencies or turn decoders off. I only use ogg and all three libraries (not incluiding SDL itself) compile just fine under Windows.

Reply 3 of 12, by lucky7456969

User metadata
Rank Oldbie
Rank
Oldbie

Could you show me how do I turn decoders off? Just like you, I'd like to have ogg installed as my personal preference
I thought there were #define's to exclude or exclude libs out.
Let me know
Thanks
Jack

Reply 4 of 12, by Dominus

User metadata
Rank DOSBox Moderator
Rank
DOSBox Moderator

If you use mingw you can do stuff like that through configure switches.
In msys cd to the folder with SDL_sound and run
./configure --help
Now you'll see available options. Configure will recognize which libs are installed on its own normally, though.

If you use visual c you will need to find other ways. I never used that

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 7 of 12, by lucky7456969

User metadata
Rank Oldbie
Rank
Oldbie

Hello,
Although I didn't want to have the rest of the codecs, strange enough, I am able to compile SDL_Sound by luck.
However, when I link it with VS2010,
I got the following error

Error	3	error LNK1104: cannot open file 'LIBC.lib'	E:\Jacky\Downloads\dosbox\sdl_sound_visualc_srcs\SDL_sound\visualc\LINK	sdl_sound_dll

I found that the project was pointing to the smpeg.h at ..\..\smpeg\smpeg
now I add one line before it, E:\Jacky\Downloads\dosbox\sdl_sound_visualc_srcs\SDL_sound;
Then it is able to be compiled, not linked.
Thanks
Jack

Reply 9 of 12, by lucky7456969

User metadata
Rank Oldbie
Rank
Oldbie
Error	3	error LNK2019: unresolved external symbol _ov_time_total referenced in function _OGG_open	E:\sdl_sound\SDL_sound\VisualC\ogg.obj	sdl_sound_dll
Error 4 error LNK2019: unresolved external symbol _ov_clear referenced in function _OGG_open E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 5 error LNK2019: unresolved external symbol _ov_info referenced in function _OGG_open E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 6 error LNK2019: unresolved external symbol _ov_open_callbacks referenced in function _OGG_open E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 7 error LNK2019: unresolved external symbol _ov_read referenced in function _OGG_read E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 8 error LNK2019: unresolved external symbol _ov_raw_seek referenced in function _OGG_rewind E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 9 error LNK2019: unresolved external symbol _ov_time_seek referenced in function _OGG_seek E:\sdl_sound\SDL_sound\VisualC\ogg.obj sdl_sound_dll
Error 10 error LNK1120: 7 unresolved externals E:\sdl_sound\SDL_sound\VisualC\win32lib\sdl_sound_d.dll 1 1 sdl_sound_dll

It seems to be errors and looking for the right libvorbis.lib

Thanks
Jack

Reply 11 of 12, by lucky7456969

User metadata
Rank Oldbie
Rank
Oldbie

Thanks, I finally sort out everything except this. My final final final error

extern "C" int _nhandle;
bool Network_CloseFile(Bit16u entry)
{
Bit32u handle=RealHandle(entry);
int _Expr_val=!!((handle >= 0 && (unsigned)handle < (unsigned)_nhandle));
//_ASSERT_EXPR( ( _Expr_val ), _CRT_WIDE(#(handle >= 0 && (unsigned)handle < (unsigned)_nhandle)) );
if (!(handle > 0) || ( !( _Expr_val ))) {
_doserrno = 0L;
errno = EBADF;
dos.errorcode=(Bit16u)_doserrno;
return false;
}

if(close(handle)==0)
{
NetworkHandleList[entry]=0;

DOS_PSP psp(dos.psp());
psp.SetFileHandle(entry,0xff);

return true;
}
else
{
dos.errorcode=(Bit16u)_doserrno;
return false;
}
}//bool Network_CloseFile(Bit16u entry)
Error	3	error LNK2001: unresolved external symbol __nhandle	E:\ykhwong\visualc_net\dos_files.obj	dosbox