1. Use the autogen.sh script to generate makefile-related files.
autogen.sh
2. Use `make` to execute the `makefile`
make
### Command operation principle
#### .in file - "Template file"
1. Makefile.in: A template for Makefile. It is filled with placeholder variables such as @srcdir@, @CC@, @prefix@, etc. Configure replaces these variables with actual values, outputting a directly usable Makefile.
2. config.h.in: A header file template. The configure script will generate config.h based on the detection results, which defines macros such as #define HAVE_STDLIB_H 1 for use in the source code.
3. Why is it called .in? It stands for input template, waiting to be filled by configure.
#### .m4 file - "Macro definition file"
1. m4 is an ancient macro processing language used by Autoconf to extend configure.ac.
2. aclocal.m4: Generated by aclocal, it contains macros written by the project itself and macros installed by the system (such as macros for detecting a specific library), intended for use by autoconf.
3. pkg.m4: This is a macro file provided by the pkg-config tool, which defines macros such as PKG_CHECK_MODULES, intended for conveniently detecting dependent libraries in configure.ac. Your script checks for its existence to ensure that the project can correctly detect dependencies.
4. Other .m4 files: They are usually stored in /usr/share/aclocal and are detection macros provided by various third-party libraries.