Allegro.cc - Online Community

Allegro.cc Forums » Installation, Setup & Configuration » Having problems building monolith

Credits go to Edgar Reynaldo for helping out!
This thread is locked; no one can reply to it. rss feed Print
Having problems building monolith
Michael Weiss
Member #223
April 2000

I am trying to build the allegro monolith library on ubuntu 22.04.

I have followed the instructions from SiegeLord here:

https://github.com/liballeg/allegro_wiki/wiki/Install-Allegro-from-source-on-Ubuntu

I can build Allegro successfully following the instructions exactly, but I want to build the monolith.

I got it to work a few years ago and I am not sure what I am doing differently this time.

So what I do differently to create the monolith is:

mkdir build
cd build
cmake ..

after these commands I run:

ccmake ..

Then change:
WANT_MONOLITH ON

but when I type 'c' and configure I get this error:

CMake Error at CMakeLists.txt:1238 (install):
install TARGETS given target "allegro" which does not exist.

In my notes from years ago I used ccmake to turn off many things I did not need. Now when I try that I get various errors about targets that don't exist.

What am I doing wrong?

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Use a single cmake build tool. Because they will all use the same CMakeCache.txt, which you may need to delete by now.

Yes, you were doing it right, you should be able to accomplish the same thing by passing options to cmake on the command line. Like so :

cmake -DWANT_MONOLITH=On -DCMAKE_BUILD_TYPE=Debug ..

EDIT
There may also be an error in CMakeLists.txt that tries to install the addons instread of the monolith for the allegro target.

Michael Weiss
Member #223
April 2000

Ok I will experiment with that, Thanks.

I am not familiar with cmake and ccmake at all.

I just tried to blindly follow the instructions, but when something unexpected happened I had no idea what to do.

I started from scratch a few times. Deleted everything.

The next time I try, will just use one or the other.

Edit:

I got it to work:

I could not get ccmake to work at all.
If I run it first, it comes up blank and says 'empty cache'
If I run 'cmake ..' then 'ccmake ..' I get all the options, but get the missing target errors.

So I just use cmake and pass it all the options.

Something else I was doing wrong:
Do not run cmake more than once! I get the same missing target errors doing that.

Funny thing, from my notes from a few years ago, I was using ccmake and it worked.

Anyway I like passing the options to cmake better tham manually setting them with ccmake.

Here is the final procedure than worked for me:

git clone https://github.com/liballeg/allegro5.git
cd allegro5
mkdir build
cd build
cmake -DCMAKE_BUILD_TYPE=Release -DWANT_MONOLITH=ON -DWANT_D3D=OFF -DWANT_D3D9EX=OFF -DWANT_DEMO=OFF -DWANT_DLL_TLS=OFF -DWANT_DOCS=OFF -DWANT_DOCS_HTML=OFF -DWANT_DOCS_INFO=OFF -DWANT_DOCS_MAN=OFF -DWANT_DOCS_PDF=OFF -DWANT_DOCS_PDF_PAPER=OFF -DWANT_NATIVE_IMAGE_LOADER=OFF -DWANT_OPENAL=OFF -DWANT_VIDEO=OFF -DWANT_VORBIS=OFF -DWANT_IMAGE_FREEIMAGE=OFF -DWANT_IMAGE_JPG=OFF -DWANT_IMAGE_PNG=OFF -DWANT_IMAGE_WEBP=OFF -DWANT_LUAJIT=OFF -DWANT_MEMFILE=OFF -DWANT_MODAUDIO=OFF -DWANT_EMBED=OFF -DWANT_EXAMPLES=OFF -DWANT_FLAC=OFF -DFREETYPE_BZIP2=OFF -DFREETYPE_HARFBUZZ=OFF -DFREETYPE_PNG=OFF -DFREETYPE_ZLIB=OFF -DWANT_ALSA=OFF -DWANT_AQUEUE=OFF -DWANT_FRAMEWORKS=OFF -DWANT_GLES3=OFF -DWANT_MP3=OFF -DWANT_MUDFLAP=OFF -DWANT_OPENSL=OFF -DWANT_OPUS=OFF -DWANT_OSS=OFF -DWANT_PHYSFS=OFF -DWANT_POPUP_EXAMPLES=OFF -DWANT_PYTHON_WRAPPER=OFF -DWANT_RELEASE_LOGGING=OFF -DWANT_SHADERS_D3D=OFF -DWANT_STATIC_RUNTIME=OFF -DWANT_TESTS=OFF -DWANT_TREMOR=OFF -DWANT_WAIT_EVENT_SLEEP=OFF -DSTRICT_WARN=OFF -DWANT_ACODEC_DYNAMIC_LOAD=OFF ..
make
sudo make install

Edgar Reynaldo
Major Reynaldo
May 2007
avatar

Go to: