Skip to content

Commit

Permalink
Remove LONG DOUBLE support
Browse files Browse the repository at this point in the history
  • Loading branch information
caiiiycuk committed Dec 20, 2023
1 parent 74d0136 commit f276bfe
Show file tree
Hide file tree
Showing 11 changed files with 50 additions and 22 deletions.
9 changes: 8 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -50,4 +50,11 @@ src/dos/sokol/sokol
dist
bench

emscripten
emscripten
*.o
CMakeFiles
cmake_install.cmake
CMakeCache*
.ninja*
build.ninja
dosbox-x-sdl2*
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ set(TARGETS_DIR "${CMAKE_CURRENT_LIST_DIR}/targets")

# add_compile_options(-fno-exceptions)

set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w -Werror=return-type")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w -Werror=return-type")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -w -Werror=return-type -fsigned-char")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -w -Werror=return-type -fsigned-char")

if ((CMAKE_BUILD_TYPE STREQUAL "Debug") OR (CMAKE_BUILD_TYPE STREQUAL ""))
message(STATUS "DEBUG BUILD")
Expand Down
2 changes: 1 addition & 1 deletion gulpfile.ts/cmake.ts
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ export default async function make(listsPath: string,
}

async function makeBuild(...targets: string[]) {
await execute("ninja", "-j4", ...targets);
await execute("ninja", "-j16", ...targets);
}

async function emcmake(listsPath: string) {
Expand Down
2 changes: 1 addition & 1 deletion native/dosbox-x
16 changes: 11 additions & 5 deletions native/jsdos/dosbox-x/jsdos-x-main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ typedef enum PROCESS_DPI_AWARENESS {
} PROCESS_DPI_AWARENESS;
#endif

#if C_EMSCRIPTEN
#if EMSCRIPTEN
# include <emscripten.h>
#endif

Expand Down Expand Up @@ -3012,10 +3012,12 @@ void GFX_EndUpdate(const uint16_t *changedLines) {

if (changedLines) {
std::vector<uint32_t> lines;
// TODO: @caiiiycuk menu?
lines.push_back(0);
lines.push_back(sdl.clip.y);
lines.push_back(0);

if (sdl.clip.y > 0) {
lines.push_back(0);
lines.push_back(sdl.clip.y);
lines.push_back(0);
}

Bitu y = 0, index = 0;
while (y < sdl.draw.height) {
Expand Down Expand Up @@ -9804,3 +9806,7 @@ int server_run() {
jsdos::destroyAsyncify();
return code;
}

void server_mouse_sync(uint64_t syncMs) {
// not supported
}
11 changes: 10 additions & 1 deletion native/jsdos/dosbox-x/jsdos-x-mixer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,15 @@ constexpr int PUSH_SIZE = 512;
float blockBuffer[BLOCK_SIZE];
static void MIXER_CallBack(float *stream, int len);

bool muted = false;
void server_mute() {
muted = true;
}

void server_unmute() {
muted = false;
}

static INLINE int16_t MIXER_CLIP(Bits SAMP) {
if (SAMP < MAX_AUDIO) {
if (SAMP > MIN_AUDIO)
Expand Down Expand Up @@ -876,7 +885,7 @@ static void MIXER_Mix(void) {
samplesCount = BLOCK_SIZE;
}
MIXER_CallBack(blockBuffer, samplesCount);
if (!mixer.mute) {
if (!mixer.mute && !muted) {
client_sound_push(blockBuffer, samplesCount);
}
pushedAt = now;
Expand Down
1 change: 1 addition & 0 deletions native/jsdos/jsdos-log.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ void Logger::operator()(char const* format, ...) {
#endif

static char buf[1024];
buf[1023] = 0;

va_list msg;
va_start(msg, format);
Expand Down
14 changes: 7 additions & 7 deletions src/build.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,26 +5,26 @@
// gulpfile.ts/wasm.ts --> generateBuildInfo

export const Build = {
version: "0.80.20 (8e0d4ea40b30b7a6059a80f062f80b7c)",
buildSeed: 1701004064067,
version: "0.80.20 (bd241dfce32911cec7d1f8ddc6ad72cf)",
buildSeed: 1702843822000,
"wdosbox-x.wasm": {
"size": 6498396,
"size": 6415326,
"gzSize": 0
},
"wdosbox-x.js": {
"size": 251980,
"size": 251608,
"gzSize": 0
},
"wdosbox.wasm": {
"size": 1465293,
"size": 1455163,
"gzSize": 0
},
"wdosbox.js": {
"size": 128379,
"size": 127892,
"gzSize": 0
},
"wlibzip.wasm": {
"size": 111427,
"size": 108831,
"gzSize": 0
},
"wlibzip.js": {
Expand Down
3 changes: 2 additions & 1 deletion src/protocol/protocol.ts
Original file line number Diff line number Diff line change
Expand Up @@ -220,6 +220,7 @@ export class CommandInterfaceOverTransportLayer implements CommandInterface {
})
.catch((e) => {
this.onErr("panic", "Can't send bundles to backend: " + e.message);
console.error(e);
})
.finally(() => {
delete this.init;
Expand Down Expand Up @@ -359,7 +360,7 @@ export class CommandInterfaceOverTransportLayer implements CommandInterface {

private onFrameLines(lines: FrameLine[], rgbaPtr: number) {
for (const line of (lines as FrameLine[])) {
(this.rgb as Uint8Array).set(line.heapu8, line.start * this.frameWidth * 3);
this.rgb!.set(line.heapu8, line.start * this.frameWidth * 3);
}

this.eventsImpl.fireFrame(this.rgb, this.rgba);
Expand Down
2 changes: 1 addition & 1 deletion targets/dosbox-x-asyncify.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
["BIOS::cb_bios_boot__func","BIOS::cb_bios_post__func","BIOS::cb_bios_startup_screen__func","BIOS_Int10RightJustifiedPrint","BOOT::Run","BOOT::printError","CALLBACK_Idle","CALLBACK_RunRealFar","CALLBACK_RunRealInt","CHOICE::Run","CPU_ForceV86FakeIO_In","CPU_ForceV86FakeIO_Out","ConnectToServer","DOSBOX_RunMachine","DOS_21Handler","DOS_CheckExtDevice","DOS_CloseFile","DOS_CreateFile","DOS_Device::GetInformation","DOS_Device::Read","DOS_Device::Write","DOS_FindDevice","DOS_FlushSTDIN","DOS_GetSTDINStatus","DOS_MakeDir","DOS_OpenFile","DOS_ReadFile","DOS_Shell::BuildCompletions","DOS_Shell::CMD_CHDIR","DOS_Shell::CMD_CLS","DOS_Shell::CMD_COPY","DOS_Shell::CMD_DELETE","DOS_Shell::CMD_DIR","DOS_Shell::CMD_ECHO","DOS_Shell::CMD_PAUSE","DOS_Shell::CMD_TYPE","DOS_Shell::CMD_VOL","DOS_Shell::DoCommand","DOS_Shell::Execute","DOS_Shell::ParseLine","DOS_Shell::Prepare","DOS_Shell::Run","DOS_Shell::ShowPrompt","DOS_Shell::execute_shell_cmd","DOS_WriteFile","EGA16_FillRow","ExceptionPageHandler::Exception","ExceptionPageHandler::writeb","ExceptionPageHandler::writed","ExceptionPageHandler::writew","FinishSetMode","IDE_DelayedCommand","IDE_SelfIO_In","IDE_SelfIO_Out","IMGMAKE::Run","IMGMAKE::printHelp","IMGMOUNT::DetectGeometry","IMGMOUNT::MountFat","IMGMOUNT::MountImageNone","IMGMOUNT::Run","INT10_Handler","INT10_LoadFont","INT10_PutPixel","INT10_ReloadFont","INT10_ScrollWindow","INT10_SetActivePage","INT10_SetCursorPos","INT10_SetCursorShape","INT10_SetSingleDACRegister","INT10_SetVideoMode","INT10_TeletypeOutput","INT10_TeletypeOutputAttr","INT10_ToggleBlinkingBit","INT10_WriteChar","INT13_DiskHandler","INT15_Handler","INT8_Handler","IO_ReadB","IO_WriteB","IPXNET::Run","MEM_BlockCopy","MOUNT::Run","NewInitPageHandler::InitPage","NewInitPageHandler::readb","NewInitPageHandler::writeb","NewInitPageHandler::writew","Normal_Loop","PAGING_NewPageFault","PROGRAMS_Handler","Program::WriteOut","Program::WriteOut_NoParsing","SDLNet_TCP_Send","SHELL_Init","SHELL_Run","VGA_ROM_BIOS_ENTRY_callback_func","WriteChar","asyncify_sleep","backone","byn$mgfn-shared$IO_ReadB","byn$mgfn-shared$IO_WriteB","device_CON::AdjustCursorPosition","device_CON::GetInformation","device_CON::Output","device_CON::Read","device_CON::Real_INT10_SetCursorPos","device_CON::Real_INT10_TeletypeOutput","device_CON::Real_INT10_TeletypeOutputAttr","device_CON::Write","fatDrive::FileCreate","fatDrive::MakeDir","fatFile::Close","fatFile::Flush","fatFromDOSDrive::GetUnmodifiedSector","fatFromDOSDrive::ReadSector","imageDisk::Read_AbsoluteSector","imageDisk::Read_Sector","imageDisk::Write_Sector","initcodepagefont","jsdos::SockDrive::Read_AbsoluteSector","jsdos::SockDrive::create","jsdos_main","localFile::Close","localFile::Flush","localFile::Read","localFile::UpdateLocalDateTime","mem_memcpy","mem_readb","mem_writeb","mem_writed","mem_writew","outc","runRuntime","server_network_connect","server_run","showWelcome","time_t_to_DOS_DateTime","BIOS::cb_bios_boot__func(*)*","BIOS::cb_bios_post__func(*)*","BIOS::cb_bios_startup_screen__func(*)*","BIOS_Int10RightJustifiedPrint(*)*","BOOT::Run(*)*","BOOT::printError(*)*","CALLBACK_Idle(*)*","CALLBACK_RunRealFar(*)*","CALLBACK_RunRealInt(*)*","CHOICE::Run(*)*","CPU_ForceV86FakeIO_In(*)*","CPU_ForceV86FakeIO_Out(*)*","ConnectToServer(*)*","DOSBOX_RunMachine(*)*","DOS_21Handler(*)*","DOS_CheckExtDevice(*)*","DOS_CloseFile(*)*","DOS_CreateFile(*)*","DOS_Device::GetInformation(*)*","DOS_Device::Read(*)*","DOS_Device::Write(*)*","DOS_FindDevice(*)*","DOS_FlushSTDIN(*)*","DOS_GetSTDINStatus(*)*","DOS_MakeDir(*)*","DOS_OpenFile(*)*","DOS_ReadFile(*)*","DOS_Shell::BuildCompletions(*)*","DOS_Shell::CMD_CHDIR(*)*","DOS_Shell::CMD_CLS(*)*","DOS_Shell::CMD_COPY(*)*","DOS_Shell::CMD_DELETE(*)*","DOS_Shell::CMD_DIR(*)*","DOS_Shell::CMD_ECHO(*)*","DOS_Shell::CMD_PAUSE(*)*","DOS_Shell::CMD_TYPE(*)*","DOS_Shell::CMD_VOL(*)*","DOS_Shell::DoCommand(*)*","DOS_Shell::Execute(*)*","DOS_Shell::ParseLine(*)*","DOS_Shell::Prepare(*)*","DOS_Shell::Run(*)*","DOS_Shell::ShowPrompt(*)*","DOS_Shell::execute_shell_cmd(*)*","DOS_WriteFile(*)*","EGA16_FillRow(*)*","ExceptionPageHandler::Exception(*)*","ExceptionPageHandler::writeb(*)*","ExceptionPageHandler::writed(*)*","ExceptionPageHandler::writew(*)*","FinishSetMode(*)*","IDE_DelayedCommand(*)*","IDE_SelfIO_In(*)*","IDE_SelfIO_Out(*)*","IMGMAKE::Run(*)*","IMGMAKE::printHelp(*)*","IMGMOUNT::DetectGeometry(*)*","IMGMOUNT::MountFat(*)*","IMGMOUNT::MountImageNone(*)*","IMGMOUNT::Run(*)*","INT10_Handler(*)*","INT10_LoadFont(*)*","INT10_PutPixel(*)*","INT10_ReloadFont(*)*","INT10_ScrollWindow(*)*","INT10_SetActivePage(*)*","INT10_SetCursorPos(*)*","INT10_SetCursorShape(*)*","INT10_SetSingleDACRegister(*)*","INT10_SetVideoMode(*)*","INT10_TeletypeOutput(*)*","INT10_TeletypeOutputAttr(*)*","INT10_ToggleBlinkingBit(*)*","INT10_WriteChar(*)*","INT13_DiskHandler(*)*","INT15_Handler(*)*","INT8_Handler(*)*","IO_ReadB(*)*","IO_WriteB(*)*","IPXNET::Run(*)*","MEM_BlockCopy(*)*","MOUNT::Run(*)*","NewInitPageHandler::InitPage(*)*","NewInitPageHandler::readb(*)*","NewInitPageHandler::writeb(*)*","NewInitPageHandler::writew(*)*","Normal_Loop(*)*","PAGING_NewPageFault(*)*","PROGRAMS_Handler(*)*","Program::WriteOut(*)*","Program::WriteOut_NoParsing(*)*","SDLNet_TCP_Send(*)*","SHELL_Init(*)*","SHELL_Run(*)*","VGA_ROM_BIOS_ENTRY_callback_func(*)*","WriteChar(*)*","asyncify_sleep(*)*","backone(*)*","byn$mgfn-shared$IO_ReadB(*)*","byn$mgfn-shared$IO_WriteB(*)*","device_CON::AdjustCursorPosition(*)*","device_CON::GetInformation(*)*","device_CON::Output(*)*","device_CON::Read(*)*","device_CON::Real_INT10_SetCursorPos(*)*","device_CON::Real_INT10_TeletypeOutput(*)*","device_CON::Real_INT10_TeletypeOutputAttr(*)*","device_CON::Write(*)*","fatDrive::FileCreate(*)*","fatDrive::MakeDir(*)*","fatFile::Close(*)*","fatFile::Flush(*)*","fatFromDOSDrive::GetUnmodifiedSector(*)*","fatFromDOSDrive::ReadSector(*)*","imageDisk::Read_AbsoluteSector(*)*","imageDisk::Read_Sector(*)*","imageDisk::Write_Sector(*)*","initcodepagefont(*)*","jsdos::SockDrive::Read_AbsoluteSector(*)*","jsdos::SockDrive::create(*)*","jsdos_main(*)*","localFile::Close(*)*","localFile::Flush(*)*","localFile::Read(*)*","localFile::UpdateLocalDateTime(*)*","mem_memcpy(*)*","mem_readb(*)*","mem_writeb(*)*","mem_writed(*)*","mem_writew(*)*","outc(*)*","runRuntime(*)*","server_network_connect(*)*","server_run(*)*","showWelcome(*)*","time_t_to_DOS_DateTime(*)*"]
["BIOS::cb_bios_boot__func","BIOS::cb_bios_post__func","BIOS::cb_bios_startup_screen__func","BIOS_Int10RightJustifiedPrint","BOOT::Run","BOOT::printError","CALLBACK_Idle","CALLBACK_RunRealFar","CALLBACK_RunRealInt","CHOICE::Run","CPU_ForceV86FakeIO_In","CPU_ForceV86FakeIO_Out","ConnectToServer","DOSBOX_RunMachine","DOS_21Handler","DOS_CheckExtDevice","DOS_CloseFile","DOS_CreateFile","DOS_Device::GetInformation","DOS_Device::Read","DOS_Device::Write","DOS_FindDevice","DOS_FlushSTDIN","DOS_GetSTDINStatus","DOS_IOCTL","DOS_MakeDir","DOS_OpenFile","DOS_ReadFile","DOS_Shell::BuildCompletions","DOS_Shell::CMD_CHDIR","DOS_Shell::CMD_CLS","DOS_Shell::CMD_COPY","DOS_Shell::CMD_DELETE","DOS_Shell::CMD_DIR","DOS_Shell::CMD_ECHO","DOS_Shell::CMD_PAUSE","DOS_Shell::CMD_TYPE","DOS_Shell::CMD_VOL","DOS_Shell::DoCommand","DOS_Shell::Execute","DOS_Shell::InputCommand","DOS_Shell::ParseLine","DOS_Shell::Prepare","DOS_Shell::Run","DOS_Shell::ShowPrompt","DOS_Shell::execute_shell_cmd","DOS_WriteFile","EGA16_FillRow","ExceptionPageHandler::Exception","ExceptionPageHandler::writeb","ExceptionPageHandler::writed","ExceptionPageHandler::writew","FinishSetMode","IDE_DelayedCommand","IDE_EmuINT13DiskReadByBIOS","IDE_SelfIO_In","IDE_SelfIO_Out","IMGMAKE::Run","IMGMAKE::printHelp","IMGMOUNT::DetectGeometry","IMGMOUNT::MountFat","IMGMOUNT::MountImageNone","IMGMOUNT::Run","INT10_Handler","INT10_LoadFont","INT10_PutPixel","INT10_ReloadFont","INT10_ScrollWindow","INT10_SetActivePage","INT10_SetCursorPos","INT10_SetCursorShape","INT10_SetSingleDACRegister","INT10_SetVideoMode","INT10_TeletypeOutput","INT10_TeletypeOutputAttr","INT10_ToggleBlinkingBit","INT10_WriteChar","INT13_DiskHandler","INT15_Handler","INT8_Handler","IO_ReadB","IO_WriteB","IPXNET::Run","MEM_BlockCopy","MOUNT::Run","NewInitPageHandler::InitPage","NewInitPageHandler::readb","NewInitPageHandler::writeb","NewInitPageHandler::writew","Normal_Loop","PAGING_NewPageFault","PROGRAMS_Handler","Program::WriteOut","Program::WriteOut_NoParsing","SDLNet_TCP_Send","SHELL_Init","SHELL_Run","VGA_ROM_BIOS_ENTRY_callback_func","VM_Boot_DOSBox_Kernel","WriteChar","asyncify_sleep","backone","byn$mgfn-shared$IO_ReadB","byn$mgfn-shared$IO_WriteB","device_CON::AdjustCursorPosition","device_CON::GetInformation","device_CON::Output","device_CON::Read","device_CON::Real_INT10_SetCursorPos","device_CON::Real_INT10_TeletypeOutput","device_CON::Real_INT10_TeletypeOutputAttr","device_CON::Write","fatDrive::FileCreate","fatDrive::MakeDir","fatFile::Close","fatFile::Flush","fatFromDOSDrive::GetUnmodifiedSector","fatFromDOSDrive::ReadSector","imageDisk::Read_AbsoluteSector","imageDisk::Read_Sector","imageDisk::Write_Sector","increaseticks","initcodepagefont","jsdos::SockDrive::Read_AbsoluteSector","jsdos::SockDrive::create","jsdos_main","localFile::Close","localFile::Flush","localFile::Read","localFile::UpdateLocalDateTime","mem_memcpy","mem_readb","mem_writeb","mem_writed","mem_writew","outc","runRuntime","server_network_connect","server_run","showWelcome","time_t_to_DOS_DateTime","BIOS::cb_bios_boot__func(*)*","BIOS::cb_bios_post__func(*)*","BIOS::cb_bios_startup_screen__func(*)*","BIOS_Int10RightJustifiedPrint(*)*","BOOT::Run(*)*","BOOT::printError(*)*","CALLBACK_Idle(*)*","CALLBACK_RunRealFar(*)*","CALLBACK_RunRealInt(*)*","CHOICE::Run(*)*","CPU_ForceV86FakeIO_In(*)*","CPU_ForceV86FakeIO_Out(*)*","ConnectToServer(*)*","DOSBOX_RunMachine(*)*","DOS_21Handler(*)*","DOS_CheckExtDevice(*)*","DOS_CloseFile(*)*","DOS_CreateFile(*)*","DOS_Device::GetInformation(*)*","DOS_Device::Read(*)*","DOS_Device::Write(*)*","DOS_FindDevice(*)*","DOS_FlushSTDIN(*)*","DOS_GetSTDINStatus(*)*","DOS_IOCTL(*)*","DOS_MakeDir(*)*","DOS_OpenFile(*)*","DOS_ReadFile(*)*","DOS_Shell::BuildCompletions(*)*","DOS_Shell::CMD_CHDIR(*)*","DOS_Shell::CMD_CLS(*)*","DOS_Shell::CMD_COPY(*)*","DOS_Shell::CMD_DELETE(*)*","DOS_Shell::CMD_DIR(*)*","DOS_Shell::CMD_ECHO(*)*","DOS_Shell::CMD_PAUSE(*)*","DOS_Shell::CMD_TYPE(*)*","DOS_Shell::CMD_VOL(*)*","DOS_Shell::DoCommand(*)*","DOS_Shell::Execute(*)*","DOS_Shell::InputCommand(*)*","DOS_Shell::ParseLine(*)*","DOS_Shell::Prepare(*)*","DOS_Shell::Run(*)*","DOS_Shell::ShowPrompt(*)*","DOS_Shell::execute_shell_cmd(*)*","DOS_WriteFile(*)*","EGA16_FillRow(*)*","ExceptionPageHandler::Exception(*)*","ExceptionPageHandler::writeb(*)*","ExceptionPageHandler::writed(*)*","ExceptionPageHandler::writew(*)*","FinishSetMode(*)*","IDE_DelayedCommand(*)*","IDE_EmuINT13DiskReadByBIOS(*)*","IDE_SelfIO_In(*)*","IDE_SelfIO_Out(*)*","IMGMAKE::Run(*)*","IMGMAKE::printHelp(*)*","IMGMOUNT::DetectGeometry(*)*","IMGMOUNT::MountFat(*)*","IMGMOUNT::MountImageNone(*)*","IMGMOUNT::Run(*)*","INT10_Handler(*)*","INT10_LoadFont(*)*","INT10_PutPixel(*)*","INT10_ReloadFont(*)*","INT10_ScrollWindow(*)*","INT10_SetActivePage(*)*","INT10_SetCursorPos(*)*","INT10_SetCursorShape(*)*","INT10_SetSingleDACRegister(*)*","INT10_SetVideoMode(*)*","INT10_TeletypeOutput(*)*","INT10_TeletypeOutputAttr(*)*","INT10_ToggleBlinkingBit(*)*","INT10_WriteChar(*)*","INT13_DiskHandler(*)*","INT15_Handler(*)*","INT8_Handler(*)*","IO_ReadB(*)*","IO_WriteB(*)*","IPXNET::Run(*)*","MEM_BlockCopy(*)*","MOUNT::Run(*)*","NewInitPageHandler::InitPage(*)*","NewInitPageHandler::readb(*)*","NewInitPageHandler::writeb(*)*","NewInitPageHandler::writew(*)*","Normal_Loop(*)*","PAGING_NewPageFault(*)*","PROGRAMS_Handler(*)*","Program::WriteOut(*)*","Program::WriteOut_NoParsing(*)*","SDLNet_TCP_Send(*)*","SHELL_Init(*)*","SHELL_Run(*)*","VGA_ROM_BIOS_ENTRY_callback_func(*)*","VM_Boot_DOSBox_Kernel(*)*","WriteChar(*)*","asyncify_sleep(*)*","backone(*)*","byn$mgfn-shared$IO_ReadB(*)*","byn$mgfn-shared$IO_WriteB(*)*","device_CON::AdjustCursorPosition(*)*","device_CON::GetInformation(*)*","device_CON::Output(*)*","device_CON::Read(*)*","device_CON::Real_INT10_SetCursorPos(*)*","device_CON::Real_INT10_TeletypeOutput(*)*","device_CON::Real_INT10_TeletypeOutputAttr(*)*","device_CON::Write(*)*","fatDrive::FileCreate(*)*","fatDrive::MakeDir(*)*","fatFile::Close(*)*","fatFile::Flush(*)*","fatFromDOSDrive::GetUnmodifiedSector(*)*","fatFromDOSDrive::ReadSector(*)*","imageDisk::Read_AbsoluteSector(*)*","imageDisk::Read_Sector(*)*","imageDisk::Write_Sector(*)*","increaseticks(*)*","initcodepagefont(*)*","jsdos::SockDrive::Read_AbsoluteSector(*)*","jsdos::SockDrive::create(*)*","jsdos_main(*)*","localFile::Close(*)*","localFile::Flush(*)*","localFile::Read(*)*","localFile::UpdateLocalDateTime(*)*","mem_memcpy(*)*","mem_readb(*)*","mem_writeb(*)*","mem_writed(*)*","mem_writew(*)*","outc(*)*","runRuntime(*)*","server_network_connect(*)*","server_run(*)*","showWelcome(*)*","time_t_to_DOS_DateTime(*)*"]
8 changes: 6 additions & 2 deletions targets/dosbox-x-sdl2.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ set(DEFINITIONS_CORE_X
# missed in libserial.cpp
-DCBAUD=0
-DCMSPAR=0
-DC_EMSCRIPTEN
)

if (${EMSCRIPTEN})
Expand Down Expand Up @@ -686,7 +687,8 @@ target_link_libraries(dosbox-x-sdl2 libdosbox-x-sdl2)
set_property(TARGET dosbox-x-sdl2 PROPERTY CXX_STANDARD 11)

if (${EMSCRIPTEN})
target_compile_options(libdosbox-x-jsdos PUBLIC -fwasm-exceptions)
target_compile_options(libdosbox-x-sdl2 PUBLIC -fwasm-exceptions)
target_include_directories(libdosbox-x-sdl2 PUBLIC "${NATIVE_DIR}/sdl2net")
set_target_properties(dosbox-x-sdl2 PROPERTIES SUFFIX .html)
target_link_options(dosbox-x-sdl2 PUBLIC
${EM_LINK_OPTIONS}
Expand All @@ -696,8 +698,10 @@ if (${EMSCRIPTEN})
"-sINVOKE_RUN=1"
"--profiling-funcs"
"-sASYNCIFY=1"
"-sASYNCIFY_IMPORTS=['syncSleep']"
)

target_compile_options(libdosbox-x-jsdos PUBLIC -fwasm-exceptions)
add_executable(wdosbox-x "${SRC_DIR}/dos/dosbox/cpp/worker-protocol.cpp")
set_target_properties(wdosbox-x PROPERTIES SUFFIX .js)
target_link_libraries(wdosbox-x libdosbox-x-jsdos libzip)
Expand All @@ -714,7 +718,7 @@ if (${EMSCRIPTEN})
"-sASYNCIFY_IMPORTS=['syncSleep']"
"-sASYNCIFY_WHITELIST=@${TARGETS_DIR}/dosbox-x-asyncify.txt"
"-sEXPORT_NAME='WDOSBOXX'"
"-sERROR_ON_UNDEFINED_SYMBOLS=0")
"-sERROR_ON_UNDEFINED_SYMBOLS=1")
elseif (APPLE)
target_link_libraries(dosbox-x-sdl2
${SDL2_LIBRARIES}
Expand Down

0 comments on commit f276bfe

Please sign in to comment.