User forums > Help

Stopped working on running and process gets terminated

<< < (2/3) > >>

stahta01:
You need to work on following directions.

From git project https://github.com/stahta01/windows-games
Edit: I just redid that git repo; to more closely match the one I forked it from.

The code that is testing the Library; I suggest you delete the library you installed on your PC;
Note: You might need to deleted Code::Blocks and the Compiler and start over if you have no idea on what to delete.

--- Code: ---#include <graphics.h>
#include <iostream>
using namespace std;

int main( )
{
    fillsettingstype f;
    initwindow(300,300);
    getfillsettings(&f);
    cout << f.pattern << endl;
    cout << f.color << endl;
    bgiout << "What's up?" << endl;
    bgiout << "Hello " << 42000;
    outstreamxy(30, 30);
    bgiout << "Bye." << endl;
    outstreamxy(150, 150);
    while (!kbhit())
delay(1000);
    return 0;
}

--- End code ---

Please read and follow the FAQs I post in the future or I will just ignore you!

Tim S.

stahta01:
An example of a full build log.


--- Code: ----------------- Clean: test-simple Debug in testbgi (compiler: GNU GCC Compiler)---------------

Cleaned "testbgi - test-simple Debug"

-------------- Build: test-simple Debug in testbgi (compiler: GNU GCC Compiler)---------------

mingw32-g++.exe -Wall -fexceptions -g -I..\include -c C:\Users\stahta01\devel\open_source_code\version_control\windows-games-git\WinBGIm\all-tests\test-simple.cxx -o ..\.objs\Debug\all-tests\test-simple.o
mingw32-g++.exe -L..\lib -o ..\bin\Debug\test-simple.exe ..\.objs\Debug\all-tests\test-simple.o   -lbgi -lgdi32 -lcomdlg32 -luuid -loleaut32 -lole32 -mwindows
Output file is ..\bin\Debug\test-simple.exe with size 1.15 MB
Process terminated with status 0 (0 minute(s), 5 second(s))
0 error(s), 0 warning(s) (0 minute(s), 5 second(s))

--- End code ---

Tim S.

xboyz:
This is the build log after running the above code;

-------------- Build: Debug in Example (compiler: GNU GCC Compiler)---------------

mingw32-g++.exe -Wall -fexceptions -g  -c "C:\Program Files\CodeBlocks\MinGW\bin\Example\main.cpp" -o obj\Debug\main.o
mingw32-g++.exe  -o bin\Debug\Example.exe obj\Debug\main.o  -lbgi -lgdi32 -lcomdlg32 -luuid -loleaut32 -lole32  "C:\Program Files\CodeBlocks\MinGW\lib\libbgi.a"
Output file is bin\Debug\Example.exe with size 1.17 MB
Process terminated with status 0 (0 minute(s), 1 second(s))
0 error(s), 0 warning(s) (0 minute(s), 1 second(s))
 

-------------- Run: Debug in Example (compiler: GNU GCC Compiler)---------------

Checking for existence: C:\Program Files\CodeBlocks\MinGW\bin\Example\bin\Debug\Example.exe
Executing: "C:\Program Files\CodeBlocks/cb_console_runner.exe" "C:\Program Files\CodeBlocks\MinGW\bin\Example\bin\Debug\Example.exe"  (in C:\Program Files\CodeBlocks\MinGW\bin\Example\.)

stahta01:
So did you compile or did you download the bgi or libbgi.a library?

If you downloaded them then you likely have a bad library!

Edit: Please learn to use code tags in your posts
http://wiki.codeblocks.org/index.php?title=FAQ-Compiling_%28general%29#Q:_How_do_I_report_a_compilation_problem_on_the_forums.3F

Tim S.

stahta01:

--- Code: ---mingw32-g++.exe  -o bin\Debug\Example.exe obj\Debug\main.o  -lbgi -lgdi32 -lcomdlg32 -luuid -loleaut32 -lole32  "C:\Program Files\CodeBlocks\MinGW\lib\libbgi.a"

--- End code ---

You should be linking to only one bgi library!!
I would try removing "C:\Program Files\CodeBlocks\MinGW\lib\libbgi.a".

Note: This is NOT likely the cause of your problem; but, might be hiding the real cause.

Tim S.

Navigation

[0] Message Index

[#] Next page

[*] Previous page

Go to full version