tomm / fab-agon-emulator

Agon Light, Agon Light 2, Agon Console8 Emulator for Linux, Windows, any system with libSDL
GNU General Public License v3.0
82 stars 19 forks source link

Error running the emulator on Windows: code: 126, kind: Uncategorized, message: "The specified module could not be found." #14

Closed tomcss closed 10 months ago

tomcss commented 10 months ago

The compiling went without problems, no errors or warning, using 'cargo build --release'. But when I try to run the application using 'cargo run --release', I get the following result at the end of this message.

I presume this is because it's not finding the VDP modules, but those didn't compile and didn't generate any module files.

> cargo run -r
    Finished release [optimized] target(s) in 0.57s
     Running `target\release\fab-agon-emulator.exe`
thread 'main' panicked at src\vdp_interface.rs:42:77:
called `Result::unwrap()` on an `Err` value: LoadLibraryExW { source: Os { code: 126, kind: Uncategorized, message: "The specified module could not be found." } }
stack backtrace:
   0:     0x7ff7a9f782ac - std::backtrace_rs::backtrace::dbghelp::trace::h782acb12622401a5
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\..\..\backtrace\src\backtrace/dbghelp.rs:98:5
   1:     0x7ff7a9f782ac - std::backtrace_rs::backtrace::trace_unsynchronized::h863bea32e8b4cd40
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\..\..\backtrace\src\backtrace/mod.rs:66:5
   2:     0x7ff7a9f782ac - std::sys_common::backtrace::_print_fmt::h8e00824771791c97
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\sys_common/backtrace.rs:67:5
   3:     0x7ff7a9f782ac - <std::sys_common::backtrace::_print::DisplayBacktrace as core::fmt::Display>::fmt::he79a180599bd168b
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\sys_common/backtrace.rs:44:22
   4:     0x7ff7a9fda27b - core::fmt::rt::Argument::fmt::h8c61f2ec76e1ae1c
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\core\src\fmt/rt.rs:138:9
   5:     0x7ff7a9fda27b - core::fmt::write::h8b5d9ba995f28b3d
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\core\src\fmt/mod.rs:1094:21
   6:     0x7ff7a9f6d6ab - std::io::Write::write_fmt::hc7addd828eb73daa
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\io/mod.rs:1714:15
   7:     0x7ff7a9f78023 - std::sys_common::backtrace::_print::he35ac4a387784684
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\sys_common/backtrace.rs:47:5
   8:     0x7ff7a9f78023 - std::sys_common::backtrace::print::h7bad5d62728e1103
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\sys_common/backtrace.rs:34:9
   9:     0x7ff7a9f7b3c6 - std::panicking::default_hook::{{closure}}::h5067abc855bf1048
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:270:22
  10:     0x7ff7a9f7b061 - std::panicking::default_hook::h240f0a26d6ddd9d1
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:290:9
  11:     0x7ff7a9f7bc3b - std::panicking::rust_panic_with_hook::hc9234f56aa852168
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:707:13
  12:     0x7ff7a9f7ba85 - std::panicking::begin_panic_handler::{{closure}}::h114d28b6ceee4a61
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:599:13
  13:     0x7ff7a9f79069 - std::sys_common::backtrace::__rust_end_short_backtrace::h94a97ff2f3d9d2cb
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src\sys_common/backtrace.rs:170:18
  14:     0x7ff7a9f7b7d0 - rust_begin_unwind
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:595:5
  15:     0x7ff7a9fd6525 - core::panicking::panic_fmt::h9985522d043fc5f1
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\core\src/panicking.rs:67:14
  16:     0x7ff7a9fd6b24 - core::result::unwrap_failed::ha7b8de540eb29961
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\core\src/result.rs:1652:5
  17:     0x7ff7a9e536de - fab_agon_emulator::vdp_interface::init::hc844fc09ab73ed9e
  18:     0x7ff7a9e4bcac - fab_agon_emulator::main::h94d09884a1f36a43
  19:     0x7ff7a9e4f66f - std::sys_common::backtrace::__rust_begin_short_backtrace::hd25c867119097af6
  20:     0x7ff7a9e4f915 - std::rt::lang_start::{{closure}}::h361ee5caa93515b3
  21:     0x7ff7a9f5e7b6 - core::ops::function::impls::<impl core::ops::function::FnOnce<A> for &F>::call_once::hb3bdf4346df38b91
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\core\src\ops/function.rs:284:13
  22:     0x7ff7a9f5e7b6 - std::panicking::try::do_call::h61c61764c4bdad62
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:502:40
  23:     0x7ff7a9f5e7b6 - std::panicking::try::hb496e09f23995746
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:466:19
  24:     0x7ff7a9f5e7b6 - std::panic::catch_unwind::h271d61ca37e37ebc
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panic.rs:142:14
  25:     0x7ff7a9f5e7b6 - std::rt::lang_start_internal::{{closure}}::hdc458e19b8f78341
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/rt.rs:148:48
  26:     0x7ff7a9f5e7b6 - std::panicking::try::do_call::h64787de3a0157676
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:502:40
  27:     0x7ff7a9f5e7b6 - std::panicking::try::h0f2ebb1d72d71417
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panicking.rs:466:19
  28:     0x7ff7a9f5e7b6 - std::panic::catch_unwind::h624df61e1023a756
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/panic.rs:142:14
  29:     0x7ff7a9f5e7b6 - std::rt::lang_start_internal::hcf82168a9de7e079
                               at /rustc/cc66ad468955717ab92600c770da8c1601a4ff33/library\std\src/rt.rs:148:20
  30:     0x7ff7a9e4e87d - main
  31:     0x7ff7a9e41395 - __tmainCRTStartup
  32:     0x7ff7a9e414e6 - mainCRTStartup
  33:     0x7ffea7c2257d - <unknown>
  34:     0x7ffea8e6aa78 - <unknown>
error: process didn't exit successfully: `target\release\fab-agon-emulator.exe` (exit code: 101)
tomcss commented 10 months ago

Running make myself for the VDP yields a file not found response:

make[1]: Entering directory `C:/source/fab-agon-emulator/src/vdp/userspace-vdp-gl/src'
g++ -Wall -O2 -fPIC -DUSERSPACE -g -std=c++11 -I. -I./dispdrivers -I./userspace-platform  -c canvas.cpp -o canvas.o
process_begin: CreateProcess(NULL, g++ -Wall -O2 -fPIC -DUSERSPACE -g -std=c++11 -I. -I./dispdrivers -I./userspace-platform -c canvas.cpp -o canvas.o, ...) failed.
make (e=2): The system cannot find the file specified.
make[1]: *** [canvas.o] Error 2
make[1]: Leaving directory `C:/source/fab-agon-emulator/src/vdp/userspace-vdp-gl/src'
make: *** [userspace-vdp-gl/vdp_gl.a] Error 2
astralaster commented 10 months ago

Is g++ in the path? And did you get the git submodules? Git submodule init and git submodule update.

tomcss commented 10 months ago

No, I just discovered it's not. I added ming64 to the path instead of mingw64.

It compiled, I copied over the .so files to firmware and it's running fine now.

I hope my incompetence will be of use to other people running into the same issue.