c++ – Cant compile raylib project with Physac

I’m trying to learn how to use raylib with physac, however I’m quite new to using a c++ compiler and after a few hours trying to get a minimal example working, I came here seeking your help.

here is my main.cpp file:

#include "raylib.h"
#include "physac.h"

int main()
{
    const int WINDOW_WIDTH = 800;
    const int WINDOW_HEIGHT = 400;

    InitWindow(WINDOW_WIDTH, WINDOW_HEIGHT, "example");
    InitPhysics();
    SetTargetFPS(60);

    while (!WindowShouldClose())
    {
        UpdatePhysics();
        BeginDrawing();
        ClearBackground(BLACK);
        EndDrawing();
    }

    CloseWindow();
    ClosePhysics();
    return 0;
}

when trying to run the file, I get the following errors:

undefined reference to `InitPhysics'
undefined reference to `UpdatePhysics'
undefined reference to `ClosePhysics'

this leads me to believe I’m missing some sort of library, here’s my g++ command:

g++ source/*.cpp -o bin/final.exe -O2 -Wall -Wno-missing-braces -I include/ -L lib/ -lraylib -lopengl32 -lgdi32 -lwinmm

My include folder only contains physac.h and raylib.h and my lib folder contains libraylib.a.
My guess is that I need some other lib file or some other flag on the compiler, but I can’t figure out what.