Arm-none-eabi to generate library files lxxx.a

How to use arm-none-eabi to generate library files, such as lxxx.a.
For example, the HAL library source file .c is compiled to generate the .a library file.
thanks