Skip to content

Program crashes when I try to run it. #7

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
HammadRehman opened this issue Jun 6, 2016 · 6 comments
Open

Program crashes when I try to run it. #7

HammadRehman opened this issue Jun 6, 2016 · 6 comments

Comments

@HammadRehman
Copy link

HammadRehman commented Jun 6, 2016

I am running the program in Release mode when I try to run the program it crashes saying "matplotlib.exe" has stopped working. I have just made new project VS2015 imported ur files and set the "Include directories" and "Library directories" path in properties. In Image attached line number is shown where program crashes in matplotlibcpp.h.
untitled

Regards

@lava
Copy link
Owner

lava commented Jun 6, 2016

Can you write a minimal, compilable example that reproduces the bug?

@HammadRehman
Copy link
Author

Steps I had done are:
Make general (Empty project) in VS 2015.
Imported matplotlibcpp.h .
used minimal.cpp as main file.
set the "Include directories" and "Library directories" path in properties. I have attached my project here. Please check it
matplotlib.zip

@lava
Copy link
Owner

lava commented Jun 7, 2016

I don't have a Windows machine, so I'm not going to be able to follow your instructions. But if you just use the minimal example without modification, my best guess would be that you're not linking libpython correctly.

@HammadRehman
Copy link
Author

I have followed this article to install python on windows machine http://www.howtogeek.com/197947/how-to-install-python-on-windows/

And I am succesfully able to print the last line which he mentioned. Do I need to install matplotlib in python seperately?? I am using python 2.7

@lava
Copy link
Owner

lava commented Jun 8, 2016

Yes, as mentioned in the "Installation"-section of the README, you need to have libpython development headers and matplotlib for python installed, so you need to run the windows-equivalent of sudo aptitude install python-matplotlib python2.7-dev.

@HammadRehman
Copy link
Author

I have installed python correctly following the above tutorial. but I haven't installed matplotlib seperatelly. I'll install matplotlib and then i'll let you know in a while.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants