gonetz / GLideN64

A new generation, open-source graphics plugin for N64 emulators.
Other
769 stars 178 forks source link

Segmentation Fault (again) #2071

Open inukaze opened 5 years ago

inukaze commented 5 years ago

Hi there i had again Segmentation Fault, like ever Release of this plugin i try to download, compile, install and use.

This time i am using "mupen64plus-ui" well to the point.

gdb ./mupen64plus-ui
GNU gdb (Debian 7.12-6) 7.12.0.20161007-git
Copyright (C) 2016 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
and "show warranty" for details.
This GDB was configured as "x86_64-linux-gnu".
Type "show configuration" for configuration details.
For bug reporting instructions, please see:
<http://www.gnu.org/software/gdb/bugs/>.
Find the GDB manual and other documentation resources online at:
<http://www.gnu.org/software/gdb/documentation/>.
For help, type "help".
Type "apropos word" to search for commands related to "word"...
Reading symbols from ./mupen64plus-ui...(no debugging symbols found)...done.
(gdb) run
Starting program: /media/Compartido/Liñux/cdf/git/mupen64plus-ui/mupen64plus-ui 
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
[New Thread 0x7fffe0b28700 (LWP 1917)]
[New Thread 0x7fffd838a700 (LWP 1921)]
[New Thread 0x7fffd72bd700 (LWP 1923)]
[New Thread 0x7fffd6abc700 (LWP 1924)]
Mupen64Plus Core v. 20509, api v. 20102, type 5, cap 1
[ui] info: Core capabilities:
[ui] info:   [x] Dynamic recompiler
[ui] info:   [ ] Debugger
[ui] info:   [ ] Core comparison
[Core] info: Updating parameter set version in 'Core' config section to 1,01
[Core] info: Using full mem base
[New Thread 0x7fffd6089700 (LWP 1926)]
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2147482986) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2130705765) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2113928544) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2097151323) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2080374102) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2063596881) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2046819660) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2030042439) are not possible
QWidget::setMaximumSize: (gridWidget/QWidget) Negative sizes (178,-2013265218) are not possible

Thread 1 "mupen64plus-ui" received signal SIGSEGV, Segmentation fault.
0x00007fffa7420d5d in PluginAPI::PluginStartup(void*) ()
   from /opt/videojuegos/emuladores/mupen64plus-git/plugin/mupen64plus-video-GLideN64.so

i had my own script to download, compile, and install mupen64plus -> here

i try this plugin from first public release "Old GL" but never works. when i try to configure or start emulation, i just ever get "Segmetation Fault"

gonetz commented 4 years ago

@inukaze can you make debug build, run it with GDB and find, on which line segmentation fault happens?

inukaze commented 4 years ago

@inukaze can you make debug build, run it with GDB and find, on which line segmentation fault happens?

How i make a debug build, its possible run GBD directly from the library without emulator?

gonetz commented 4 years ago

How i make a debug build

cmake -DCMAKE_BUILD_TYPE=Debug -DUSE_SYSTEM_LIBS=On -DMUPENPLUSAPI=On ../../src/

its possible run GBD directly from the library without emulator?

No, you should run emulator from GDB. If you are not familiar with GDB command-line interface, you may use any GUI frontend for it.

inukaze commented 4 years ago

Well i compile the debug version and i set the plugin on the mupen64plus configuration file. and i try with (mupen64plus + GLideN64 + The Legend Of Zelda Majora Mask Europe Multi4) the follow command :

$ gdb --args /usr/bin/mupen64plus ~/tlozmmesp.z64

GNU gdb (Debian 7.12-6) 7.12.0.20161007-git Copyright (C) 2016 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later http://gnu.org/licenses/gpl.html This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. Type "show copying" and "show warranty" for details. This GDB was configured as "x86_64-linux-gnu". Type "show configuration" for configuration details. For bug reporting instructions, please see: http://www.gnu.org/software/gdb/bugs/. Find the GDB manual and other documentation resources online at: http://www.gnu.org/software/gdb/documentation/. For help, type "help". Type "apropos word" to search for commands related to "word"... Reading symbols from /usr/bin/mupen64plus...done.

(gdb) run

Starting program: /usr/bin/mupen64plus /home/inukaze/tlozmmesp.z64
[Thread debugging using libthread_db enabled]
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
 __  __                         __   _  _   ____  _             
|  \/  |_   _ _ __   ___ _ __  / /_ | || | |  _ \| |_   _ ___ 
| |\/| | | | | '_ \ / _ \ '_ \| '_ \| || |_| |_) | | | | / __|  
| |  | | |_| | |_) |  __/ | | | (_) |__   _|  __/| | |_| \__ \  
|_|  |_|\__,_| .__/ \___|_| |_|\___/   |_| |_|   |_|\__,_|___/  
             |_|         https://mupen64plus.org/               
Mupen64Plus Console User-Interface Version 2.5.9

UI-Console: attached to core library 'Mupen64Plus Core' version 2.5.9
UI-Console:             Includes support for Dynamic Recompiler.
Core: Using full mem base
[New Thread 0x7fffcfa37700 (LWP 6069)]
Core: Goodname: Legend of Zelda, The - Majora's Mask (E) (M4) (V1.0) [!]
Core: Name: ZELDA MAJORA'S MASK 
Core: MD5: 13FAB67E603B002CEAF0EEA84130E973
Core: CRC: E97955C6 BC338D38
Core: Imagetype: .z64 (native)
Core: Rom size: 33554432 bytes (or 32 Mb or 256 Megabits)
Core: Version: 144B
Core: Manufacturer: Nintendo
Core: Country: Europe (0x50)
UI-Console Status: Cheat codes disabled.
UI-Console: using Video plugin: 'GLideN64' v2.0.0
UI-Console: using Audio plugin: 'Mupen64Plus SDL Audio Plugin' v2.5.9
UI-Console: using Input plugin: 'Mupen64Plus SDL Input Plugin' v2.5.9
UI-Console: using RSP plugin: 'Static Interpreter' v0.1.1
Core: input plugin did not specify a render callback; there will be no on screen display by the input plugin.
Input: 0 SDL joysticks were found.
Input: N64 Controller #1: Using manual config for SDL joystick 0
Input: N64 Controller #2: Using manual config for SDL joystick 1
Input: N64 Controller #3: Using manual config for SDL joystick 2
Input: N64 Controller #4: Using manual config for SDL joystick 0
Input: 4 controller(s) found, 3 plugged in and usable in the emulator
Input Warning: Couldn't open joystick for controller #1: There are 0 joysticks available
Input Warning: Couldn't open rumble support for joystick #1
Input Warning: Couldn't open joystick for controller #2: There are 0 joysticks available
Input Warning: Couldn't open rumble support for joystick #2
Input Warning: Couldn't open joystick for controller #3: There are 0 joysticks available
Input Warning: Couldn't open rumble support for joystick #3
Input Warning: Couldn't open joystick for controller #4: There are 0 joysticks available
Input Warning: Couldn't open rumble support for joystick #2098 4
Input: Mupen64Plus SDL Input Plugin version 2.5.9 initialized.

Thread 1 "mupen64plus" received signal SIGSEGV, Segmentation fault.
0x00007fffccdd9c10 in InitiateRSP (Rsp_Info=..., CycleCount=<optimized out>) at ../..//module.c:482
482 ../..//module.c: No existe el fichero o el directorio.
gonetz commented 4 years ago

Hmm. In your first message it was segmentation fault in PluginAPI::PluginStartup(void*), which is GLideN64 function. I hoped that GDB would show you which line caused that error. But now segmentation fault is in module.c, which is mupen64plus code. It gives me nothing.

Could you set a breakpoint at the beginning of PluginAPI::PluginStartup function and, when debugger stopped at this point, run it in the debugger line by line to the end? Will it run without issues?

inukaze commented 4 years ago

Could you set a breakpoint at the beginning of PluginAPI::PluginStartup function and, when debugger stopped at this point, run it in the debugger line by line to the end? Will it run without issues?

How, which commands i need to use for do that?

gonetz commented 4 years ago

You need to look at GDB help for that, I don't use it. You may also use some GUI front-ends for it. If you familiar with any debugger, you will find how to use it.

Also, it is possible that your system does not support OpenGL 3.3, thus the problems. GLideN64 can dump information about OpenGL context into gliden64.log, but you need to change log level first. Open src/Log.h and change #define LOG_LEVEL LOG_WARNING to #define LOG_LEVEL LOG_VERBOSE Rebuild plugin and run. The log will be in the same folder, where mupen64plus keeps saves, screeshots etc.

olivieryuyu commented 4 years ago

can it be closed?

Apteryks commented 4 months ago

@olivieryuyu 4 years later, I guess so!