---
name: "al_init"
section: "3"
platform: "linux"
package: "allegro"
version: "5.2.11.3-2"
release: "Arch Linux 2026-11-01"
platforms: ["linux"]
url: "https://new.carta.tech/al_init"
---

# al\_init(3)

Allegro 5 API

## NAME

al\_init - Allegro 5 API

## SYNOPSIS

-

  ```
  #include <allegro5/allegro.h>
  #define al_init()    (al_install_system(ALLEGRO_VERSION_INT, atexit))
  ```

## DESCRIPTION

Like [al\_install\_system(3)](/al_install_system/3.md), but automatically passes in the version and uses the atexit function visible in the current binary.

Note: It is typically wrong to call al\_init anywhere except the final game binary. In particular, do not call it inside a shared library unless you know what you’re doing. In those cases, it is better to call al\_install\_system either with a `NULL` atexit\_ptr, or with a pointer to atexit provided by the user of this shared library.

## SEE ALSO

[al\_install\_system(3)](/al_install_system/3.md)
