Pages: 1
Author Topic: Issue on linux  (44,307 Views)
Offline (Unknown gender) FroggestSpirit

Member
Joined: Mar 2013
Posts: 79
View profile
Posted on: February 27, 2014, 06:16:19 AM
I just installed ENIGMA on Xubuntu again, and after getting Catch the Clown, I get this error when compiling
http://pastebin.com/kXqxjzvH
Any ideas?
Offline (Unknown gender) Goombert

Developer
Joined: Jan 2013
Posts: 2,991
View profile
Reply #1 Posted on: February 27, 2014, 11:02:24 AM
According to Git blame, it's Harri's fault.
https://github.com/enigma-dev/enigma-dev/blame/master/ENIGMAsystem/SHELL/Graphics_Systems/OpenGL1/GLd3d.cpp
I have fixed it in the following commit to my pull request.
https://github.com/RobertBColton/enigma-dev/commit/1a6ca0f83e9854a4dee7ae8543099f95575e7577

In the mean time frogg, just go to line 241 in GLd3d.cpp and comment out the printf call. Let me know if there are more.
Offline (Unknown gender) TheExDeus

Developer
Joined: Apr 2008
Posts: 1,860
View profile
Reply #2 Posted on: February 27, 2014, 06:00:43 PM
Yeah, we need someone to test Linux once in a while. Me and Robert are only on Windows right now. Maybe I will end up installing Linux somewhere.

The error is extremely weird and shouldn't be happening. It means that default headers are not included on Linux/Mac for some reason. I just checked and almost all XLIB headers include <stdio.h>, so it's weird. Anyway, I guess the best option would be to just include <stdio.h> in GLd3d.cpp as well. It's probably the proper way anyway.

On the same topic I should also say that we need a uniform error reporting function. A function that would report errors in a nice window with selectable text (like GM) and use that everywhere. Right now error reporting is very shattered in ENIGMA. On Windows we can make a windows form to do that, but in not sure how to do the same in Linux/Mac.
Offline (Unknown gender) cheeseboy

Administrator
Joined: Mar 2011
Posts: 105
View profile
Reply #3 Posted on: February 27, 2014, 08:03:22 PM
On linux errors (are or were?) spouted to the terminal as well as lgm's console. On linux copying from the terminal is very easy. However windows has the shitiest terminal in the history of ever... It was so slow poly hid it. I think output for windows is saved to enigma_log.log or sum shit instead.
Offline (Unknown gender) Goombert

Developer
Joined: Jan 2013
Posts: 2,991
View profile
Reply #4 Posted on: February 27, 2014, 09:03:53 PM
Quote from: TheExDeusOn the same topic I should also say that we need a uniform error reporting function. A function that would report errors in a nice window with selectable text (like GM) and use that everywhere. Right now error reporting is very shattered in ENIGMA. On Windows we can make a windows form to do that, but in not sure how to do the same in Linux/Mac.
We do, it's the same function from GM8.1
http://enigma-dev.org/docs/Wiki/Show_error
Offline (Unknown gender) TheExDeus

Developer
Joined: Apr 2008
Posts: 1,860
View profile
Reply #5 Posted on: February 27, 2014, 09:38:11 PM
QuoteOn linux errors (are or were?) spouted to the terminal as well as lgm's console. On linux copying from the terminal is very easy. However windows has the shitiest terminal in the history of ever... It was so slow poly hid it. I think output for windows is saved to enigma_log.log or sum shit instead.
I know where errors are written to. The fact though is that they should be a) Shown on the screen and b) Be consistent.

QuoteWe do, it's the same function from GM8.1
We don't.
1. That function is NOT used in all places in ENIGMA (hence my need for a uniform function).
2. It doesn't do what I want. It's meant for games or programs made with ENIGMA, not ENIGMA's engine itself. So things like copying from that function or even proper formatting is impossible. What I mean is this:
http://docs.yoyogames.com/source/dadiospice/images/errorreport.png
We could even make it fancier than that.

So I propose writing a simple wiki page standardizing both the format of the error (so they are all written in a standardized way) and making a specific ENIGMA function to show the error (they function will probably not be available to users, so it's in enigma namespace). The function needs to return the instance and event the error happened in, the function name as well if possible. The function should probably be of kind:
"Error in function draw_background - Background with %ID% doesn't exist", where %ID% is the ID passed to the function. For regular compiles the errors can be less verbose and just show the position of error. This verbose variant with printing function names and error parameters should only be used in debug mode, so the size wouldn't bloat.

Any better ideas or suggestions? Maybe Robert can write a wiki page about it (my lazy excuse is that I am not a "wiki guy" :D). When we come to a consensus, then we can start implementing. Josh's input would also be appreciated, as he wrote the original error mechanism.
Offline (Unknown gender) cheeseboy

Administrator
Joined: Mar 2011
Posts: 105
View profile
Reply #6 Posted on: February 28, 2014, 09:04:20 PM
QuoteI know where errors are written to. The fact though is that they should be a) Shown on the screen and b) Be consistent.
My point was they should be written to stdout but windows is too slow for that and writing a custom error window to cater to windows shittyness is waste of time.
Offline (Unknown gender) TheExDeus

Developer
Joined: Apr 2008
Posts: 1,860
View profile
Reply #7 Posted on: March 01, 2014, 12:43:42 PM
QuoteMy point was they should be written to stdout but windows is too slow for that and writing a custom error window to cater to windows shittyness is waste of time.
No, they shouldn't. Errors actually need to be blocking. If you write to std::out, then you might not even notice an error has happened, because the game will continue going as normal. Most errors, especially in debug mode, should exit the game when that happens. And taking into account not everyone runs from console, then writing to the console would be useless (as it would just close with the game). Console was made invisible on Windows not because it was slow, but because users on windows doesn't want to see it. If I ran a game compiled in Release mode, I don't want to see a console popping up together with a game. On Windows errors are windows and they make both for a more functional and more professional look.
Offline (Unknown gender) FroggestSpirit

Member
Joined: Mar 2013
Posts: 79
View profile
Reply #8 Posted on: March 01, 2014, 04:35:54 PM
Now it says: No package 'gtk+-2.0' found
I installed all the dependencies listed in the wiki in the long sudo get-apt thing
Also it windows, it's saying that d3d_model_create isn't defined (I think for both opengl1 and opengl3)
Offline (Unknown gender) TheExDeus

Developer
Joined: Apr 2008
Posts: 1,860
View profile
Reply #9 Posted on: March 01, 2014, 07:48:38 PM
QuoteNow it says: No package 'gtk+-2.0' found
Try disabling widgets in ENIGMA settings (set it to none). I guess it tries to use gtk widgets (might be default on Linux), but for some reason you don't have them.

QuoteAlso it windows, it's saying that d3d_model_create isn't defined (I think for both opengl1 and opengl3)
Well that is weird. Are you sure you are using the newest version? Because that function isn't a problem for me while using the newest from GIT.
Offline (Unknown gender) FroggestSpirit

Member
Joined: Mar 2013
Posts: 79
View profile
Reply #10 Posted on: March 01, 2014, 09:08:20 PM
on windows, I'm using the zip installer (would the git version be newer?)

Also, how would I install the gtk widgets?
Offline (Unknown gender) Goombert

Developer
Joined: Jan 2013
Posts: 2,991
View profile
Reply #11 Posted on: March 02, 2014, 10:32:35 PM
Just fyi, I fixed the d3d_model_create issue on IRC, it was an issue with the EGM being out of date he had to patch the table of contents and rename EXT Extensions to PKG Extension Packages and Extensions.ey to Extension Packages.ey and then I had him open and save the EGM to add make-directory to ENIGMA settings and after that it worked fine.
Pages: 1