GOCR for Windows From Linux

My last post was a major screw up. I admit it. Maybe I was high, but whatever I posted some shit, someone called me out on it. Ah well, big deal. I post some good stuff I reckon. Totally for free. If you can’t read through some of my bullshit to get to it then I will clean you up the proper info for a small fee of $600. But I guess you’re all just going to have to read my shit along with the good stuff. Am I retarded? Hell yeah. But I don’t give a fuck.

Anyway instead of rebooting your pc everytime you want to compile a program for windows it’s actually possible to compile straight from Linux with wine. This includes ImageMagick programs. Now I’m not sure but I think some other folks have tutorials on similar stuff but it’s a pain to get imagemagick included as well. Here’s how you do it.

Go download dev-cpp we’ll use this as our IDE

Now go get the latest MingW. You’ll know you’ve got the right one because in dev-cpp/bin/ you’ll find a load of same named files as in MinGW/bin/.

Copy the files from MinGW/bin/ over the dev-cpp/bin/ directory. This is basically an update of MinGW. Oh yeah copy over the libraries (lib/) too, I’m pretty sure you need those. Something about gettimeofday() not being present in older versions of mingw.

Download the ImageMagick for MinGW install. It’s listed under the unix binaries but runs on windows. No idea why. Anyway this will install a directory with some libraries in it. Libraries are files that have an .a extension like libMagick.a

Ok right if you’ve done all that you can go ahead and run Dev-Cpp. Like this (Make sure you’ve installed it using wine:

user[~]$ cd .wine/drive_c/Dev-Cpp/

user[Dev-Cpp]$ wine devcpp.exe

and make a commandline C++ project and set the include directory to C:\ImageMagick…\include\ and add these three libraries in this order:

C:/ImageMagick-6.3.7/lib/libMagick++.a
C:/ImageMagick-6.3.7/lib/libWand.a
C:/ImageMagick-6.3.7/lib/libMagick.a

Change Include DirectoryAdd Libraries

That will now compile perfectly but when it comes to linking it will complain that there is a billion functions missing. That’s because they didn’t include all the other libraries you need. Which is what this tutorial is really about. Basically I went in search of them all and now I’ve got them I’ll zip them up for everyone. The other files you need are (you can probably just paste this into your project properties):

C:/Dev-Cpp/otherlib/libfreetype.a
C:/Dev-Cpp/otherlib/libjbig.a
C:/Dev-Cpp/otherlib/libjpeg.a
C:/Dev-Cpp/otherlib/liblcms.dll.a
C:/Dev-Cpp/otherlib/libpng.a
C:/Dev-Cpp/otherlib/libtiff.a
C:/Dev-Cpp/otherlib/libtiffxx.a
C:/Dev-Cpp/otherlib/libz.a
C:/Dev-Cpp/lib/libgdi32.a

Incidentally Dev-Cpp does come with libgdi32.a, which is handy. :D

Here’s the libraries. Enjoy.

Other Libraries You Need

All my programs so far in c++ will compile to a windows .exe from linux using this method. I find it handy. Especially as windows refuses to install because linux is on my first hard disk.

38 Responses to “GOCR for Windows From Linux”

  1. Martin Says:

    Why does someone want to struggle around with Windows, when there is Linux? I still can’t imagine…

  2. Crni Says:

    No no no … Windows … noooo … :)

  3. Portafill Says:

    I think it will not be too late to see that every OS can work together I guess.

  4. Harry Says:

    Come on guys, we all know at some point you’re going to want to run something on windows. Windows will find a way to infiltrate our lives.

  5. Jez Says:

    Ditto Martin…

    It takes me less time to install Ubuntu on dual boot and set up the rest of “AMP” than it does to get WAMP working with all the extensions I need…. have a feeling it will be the same with this debacle… interesting post all the same :-)

  6. Tax Relief Says:

    Is it possible to do so?I have thought about this but failed to do any solution.

  7. Hostmonster Says:

    I have never used linux before..so i dont like tis article.

  8. Stock Vector Illustrations Says:

    I have tried several times this thing but can’t successful.This time I think the post will help me.

  9. Mark Says:

    Hah. The irony. I went to post a comment about all the s_p_am comments you have and my comment was blocked because of a “spam word”.

    What BS.

  10. ali Says:

    nice

  11. Hire programmer India Says:

    I have tried it but not working for me as well

  12. Matti Says:

    I look here again and again by and read the interesting and well written contributions. Here I would like to leave gladly a greeting from Thuringia in Germany!

  13. Pay Per Click Agency Says:

    This is very much interesting.If we can use the feature of LINUX in Windows that will be funny.

  14. anne Says:

    What an introduction! That’s so high but it made me smile!

    For Portafill: I think it will never happen. :)

  15. denver kang Says:

    I like to use LINUX. Linux and windows have their own features.So we just need to check them out ourself!

  16. hotels Says:

    Portafill: Lindows was almost the solution ;)

  17. فروشگاه اینترنتی Says:

    Hi. I will add this site to my favorite list because of it’s great articles.can you publish or refer about this subject more ?

  18. dating site software Says:

    I think the post will help me.

  19. wholesale Says:

    I have tried several times this thing but can’t successful.This time I think the post will help me.

  20. ventrilo servers Says:

    Is it from linux? I am not hearing any big news from linux sector for long time. what is going to happen to linux? can any one tell me..?

  21. Adam Gurney Says:

    Was everyone unsuccessful here as it does not work for me whatsoever. Many tries, nothing works.

  22. SBL - Image masking service provider Says:

    Nice blog.Really informative.I like to use LINUX.

    Regards,
    image masking

  23. plumbing ny Says:

    Is it from linux? I am not hearing any big news from linux sector for long time.

  24. Skip Hire UK Says:

    I look here again and again by and read the interesting and well written contributions.

  25. book Says:

    I am waiting for the time when we will get a combined OS which will be containing all the strong sides of each OS.

  26. buy essay Says:

    Why does someone want to struggle around with Windows, when there is Linux? I still can’t imagine…

  27. Webmasters Forum Says:

    I am not happy with windows . Can I install Linux on windows PC ? Help me.

  28. Left Hand Drive Cars Says:

    Why does someone want to struggle around with Windows, when there is Linux? I still can’t imagine…

  29. Add URL Says:

    Thanks for the Update…

    Nick

  30. ppc management Says:

    Hi,

    I tried but i didn’t , after reading this i got some idea home i will make it successful this time , let c……….

  31. investing Says:

    I like the post too much. thanks for the post. and keep posting.

  32. Car Accessories Says:

    Fantastic info. Thank you so much for posting this information. Actually i was searching for this info for a long time at last i found it. Thanks once again!

  33. Selling or Remodeling Says:

    Hi i got the knowledge about os thanks for sharing it here

  34. Handbags Says:

    Cool info on the Internet. I am weak in OS and now i can able to manage independently thro this post. Thank you for sharing this info.

  35. Wholesale dropship Says:

    nice post,useful info,thank you for sharing us!

  36. Skip Hire Says:

    Why does someone want to struggle around with Windows, when there is Linux? I still can’t imagine…

  37. Skip Hire Prices Says:

    No no no … Windows … noooo … :)

  38. Ashleejames Says:

    Linux is ready for most applications, he said, noting that there are telecommunications companies running mission-critical databases on Linux, and overall adoption levels are ramping up.Citing an HP-commissioned global study conducted by market-research company GCR earlier this year, Hergett said that three out of five decision makers were ready to deploy Linux for mission-critical applications within the next two years, while one in five saw that happening in five years’ time
    —————————–
    Ashleejames

    SEO

Leave a Reply

Enter this code