Reputation: 6275
My project contains 1 binary and 14 subprojects.
Each one is located in its own folder.
Each folder have Makefile.am
, Makefile.in
, and then in the Debug/Release
folders in the top of the tree there are 15 folders with the Makefile
s.
Now the latter will definitely not be in the version control as they will be continuosly changed and depend n the different OS/build system.
Now my understanding is that Makefile.am
will be written by me by modifying different rules and include headers/libraries fr the dependencies of my project. And so this file has to be in the version control - Git.
Now the Makefile.in
file is made during the autoreconf
phase and so it will be regenerated each time my software will be build. And so it shouldn't be in the version control - Git.
Am I correct? Can I safely remove Makefile.in
and add it to the .gitignore
file?
Upvotes: -1
Views: 61
Reputation: 7431
Makefile.in
is input file that is indeed generated from autotools user created Makefile.am
so it is safe to not include it in version control check-in.
One consideration should be that Makefile.in
is input file used by configure
script to generate the final Makefile
; so configure
script should be removed from version control too to make sure the clone is not "defunct" (does not come with configure
script that fails because Makefile.in
is missing).
The right thing is to have only *.am
files checked in and after checkout run whatever command (e.g. autoreconf
) that generates final configure
script (and all .in
files on the way).
Upvotes: 1