|
Fresh Windows 10 install and now I am eager to try installing Allegro again |
Tyler Wrobel
Member #16,594
November 2016
|
Hi, so my hhd crashes and I installed Windows 10 on an SSD now. I was trying really hard to install allegro and failed previously. Before I had alot of silly stuff in my Program files because GTAV installed like 3 extra Windows SDKs and I was not able to properly resolve paths and stuff like that. Was super noob at the time. I am now ready to actually do this. I have got a clean install of Windows and I am going to make this my programming laptop now so less headache. Can someone please volunteer to walk me setting up Allegro so that it actually works. I am ready to accept guidance on everything, need help picking a compiler, and etc. I've got a complete clean slate here. |
bamccaig
Member #7,536
July 2006
|
I'm not even sure where the best binary distributions are made available anymore (the community shrunk by the time Allegro 5 was released and most people got busy with life). Looks like ML has 5.0.10 in the files section. Isn't SiegeLord producing 5.1.x binaries? First you need to figure out your toolchain. Usually the options are MinGW/MSYS (GCC) or Visual Studio. You can setup a free IDE like Code::Blocks or DevCPP to use the MinGW toolchain, or you can learn to use the command line directly. I've heard that MSYS2 is much easier for actually building things, but I think it's still a bit of a pain to build all of Allegro's dependencies so you will likely want to find a binary distribution... Likely you'll need to pick your toolchain based on whatever Allegro was built with when targeting Windows to make sure they're compatible. Once you actually have the toolchain installed installing Allegro should be pretty simple. Mostly there's only a few steps: 1. Extract the Allegro files somewhere. Once we figure out where to get the best Allegro distributions and which toolchain you need we can go from there... -- acc.js | al4anim - Allegro 4 Animation library | Allegro 5 VS/NuGet Guide | Allegro.cc Mockup | Allegro.cc <code> Tag | Allegro 4 Timer Example (w/ Semaphores) | Allegro 5 "Winpkg" (MSVC readme) | Bambot | Blog | C++ STL Container Flowchart | Castopulence Software | Check Return Values | Derail? | Is This A Discussion? Flow Chart | Filesystem Hierarchy Standard | Clean Code Talks - Global State and Singletons | How To Use Header Files | GNU/Linux (Debian, Fedora, Gentoo) | rot (rot13, rot47, rotN) | Streaming |
Chris Katko
Member #1,881
January 2002
|
If I could make a recommendation, as a Windows user and professional Windows app developer... Get Linux in a virtual machine. (VMWare Player is free. Then you just feed it an Ubuntu ISO and you're up and running.) Programming is so much more awesome on Linux. Want Allegro? Type in a terminal: sudo apt-get install allegro5 DONE. This won't likely be the newest version, however. Want the BRAND newest version of Allegro? Type in a terminal: git clone https://github.com/liballeg/allegro5.git
You've now got the source of the most recent Allegro in whatever directory you were in. Now, go in there, cd allegro5 or whatever. Run ./configure
make
make install
configure checks to make sure you have all required system dependencies. BOOM. HEADSHOT. Every bug that's been fixed in github, is now fixed on your installation. Of course, this won't be for everyone. And maybe it won't suit you. But if you've ever been on-the-fence about Linux, I REALLY encourage you to try it while you're at it. I use Ubuntu every day on my netbook, for work and fun, and work on Allegro games. I don't regret learning it at all, and the tools and mindset I've learned from cross-training has helped me solve problems on Window as well. -----sig: |
bamccaig
Member #7,536
July 2006
|
Errrr, pretty sure those build instructions won't work for Allegro. Allegro 4.4 and 5 use cmake as their build system. The build instructions are more like: mkdir build cd build cmake .. make make install In any case, it is definitely much easier to get going with Linux, but the virtual machine might throw some hardballs your way in terms of performance. If you have the space and ambition, installing a dual-boot setup is generally the easy button, but there is obviously a lot of time lost switching between OSes. In time though, you may find that you don't need one of them. OK, that's enough cheer-leading. Still trying to work out the Windows distribution situation... -- acc.js | al4anim - Allegro 4 Animation library | Allegro 5 VS/NuGet Guide | Allegro.cc Mockup | Allegro.cc <code> Tag | Allegro 4 Timer Example (w/ Semaphores) | Allegro 5 "Winpkg" (MSVC readme) | Bambot | Blog | C++ STL Container Flowchart | Castopulence Software | Check Return Values | Derail? | Is This A Discussion? Flow Chart | Filesystem Hierarchy Standard | Clean Code Talks - Global State and Singletons | How To Use Header Files | GNU/Linux (Debian, Fedora, Gentoo) | rot (rot13, rot47, rotN) | Streaming |
SiegeLord
Member #7,827
October 2006
|
Aside from the VM, the easiest way to use Allegro on Windows is to install Visual Studio 2017 and then follow this tutorial: https://wiki.allegro.cc/index.php?title=Windows,_Visual_Studio_2015_and_Nuget_Allegro_5 You could also use the MinGW/MSYS based approaches, but they are somewhat more involved. I'd just go with MSVC and move on to the other options once you've got more experience under your belt. "For in much wisdom is much grief: and he that increases knowledge increases sorrow."-Ecclesiastes 1:18 |
Tyler Wrobel
Member #16,594
November 2016
|
I am really trying to stick to Windows for now. As for Visual Studio, I choose to do everything on the command line. I don't like Visual Studio. |
bamccaig
Member #7,536
July 2006
|
I commend you for that. That said, as somebody that is mostly command line and has also had a professional career in mostly Windows I can say that Windows' command line options are really bad. It's the kind of thing that you cannot easily master, and even if you did, it would still be terrible. But I'm going to assume that you mean you intend to use MinGW/MSYS/MSYS2, not like Visual Studio's command line tools. I'm a little disappointed though. I thought we had an acceptable answer. And now I'm left scratching my head wondering where to get up-to-date MinGW-based Allegro binaries again... Append: Perhaps this is the place to be. Edgar is good people. You can trust him. And it looks like he walks you through getting the right toolchain too. Start with that and update us on where it leaves you. -- acc.js | al4anim - Allegro 4 Animation library | Allegro 5 VS/NuGet Guide | Allegro.cc Mockup | Allegro.cc <code> Tag | Allegro 4 Timer Example (w/ Semaphores) | Allegro 5 "Winpkg" (MSVC readme) | Bambot | Blog | C++ STL Container Flowchart | Castopulence Software | Check Return Values | Derail? | Is This A Discussion? Flow Chart | Filesystem Hierarchy Standard | Clean Code Talks - Global State and Singletons | How To Use Header Files | GNU/Linux (Debian, Fedora, Gentoo) | rot (rot13, rot47, rotN) | Streaming |
Tyler Wrobel
Member #16,594
November 2016
|
Ok, I will. And also to note, last time I was trying to use Mircosoft Visual build tools (i.e. the native x64 command line compiler with the intel equip linker(the most recent version.) I am just trying to understand now that should I be using the MinGW compiler to compile my projects if I am using MinGW to build? Because, I didn't have really any problems compiling other than the Micrsoft Visual compile couldn't find the recursive directories of some follow up headers after the initial one, so that shouldn't be a problem with the MinGW because the system will already have the path I am assuming? |
torhu
Member #2,727
September 2002
|
Tyler Wrobel
Member #16,594
November 2016
|
So these include paths will be set up for allegro5 if I use the MinGW compiler? |
Polybios
Member #12,293
October 2010
|
I'd say the quickest way to install a working environment of Allegro 5 is to use msys2 (and their version of MinGW). They have a package manager through which you can also many of the dependencies. However, I'll have to admit that setup can be a bit more involved, as you'll have to setup the msys2 environment first and then find your way around their pacman package manager. |
Tyler Wrobel
Member #16,594
November 2016
|
https://wiki.allegro.cc/index.php?title=Building_with_msys2 I was working from this one before, is this one you mean? So, this time I should just follow this and then use MinGW? |
Edgar Reynaldo
Major Reynaldo
May 2007
|
MSYS2 is an option for MinGW, yes, but you could just use my MinGW and Allegro 5.2.2 binaries if you wanted. All you have to do is extract twice using 7-zip and then set your path and include directories. Note : There is currently some small bug in the distro where ttf files won't load from physfs archives.. Not sure why that is happening. My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
Tyler Wrobel
Member #16,594
November 2016
|
Will this ttf thing be a problem if I want to try to build this thing later today? |
Edgar Reynaldo
Major Reynaldo
May 2007
|
It should only be a problem if you want to load ttf files from a mounted physfs archive like a zip file. If you load them separately they work fine. If you try to load them from within the archive it fails. All you need is 7-zip, and to get MinGW and Allegro 5.2.2 from here : My Website! | EAGLE GUI Library Demos | My Deviant Art Gallery | Spiraloid Preview | A4 FontMaker | Skyline! (Missile Defense) Eagle and Allegro 5 binaries | Older Allegro 4 and 5 binaries | Allegro 5 compile guide |
Polybios
Member #12,293
October 2010
|
Tyler Wrobel said: I was working from this one before, is this one you mean? So, this time I should just follow this and then use MinGW? I've revised the article. Since I somehow missed that I can't edit the wiki currently, I've posted my revised version here. |
Tyler Wrobel
Member #16,594
November 2016
|
TIME 04/01 10:43 EST I am trying to compile this https://wiki.allegro.cc/index.php?title=Allegro_5_Tutorial/Displays example code it looks like this... int main(){ if(!al_init()) { display = al_create_display(640, 480); al_clear_to_color(al_map_rgb(0,0,0)); al_rest(10.0); al_destroy_display(display); return 0; I am running and getting this... C:\msys64\tmp\ccpsquRm.o:allegrodisplay.cpp:(.text+0x22): undefined reference to `al_install_system' Also trying with Ubuntu in a Virtualbox but it says E: Unable to locate package allegro |
|