-
Notifications
You must be signed in to change notification settings - Fork 447
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add aclocal.m4 to .gitignore #733
Conversation
This is a generated file from automake, so should be included in the `.gitignore` file.
I'm not entirely sure we should hide |
Hmm ok, I was just wondering why I had a |
It's there because |
Just had a look at the README:
Surely we should ignore files that are generated by suggested methods? |
The INSTALL notes actually state to manually do Arguably we should be using aclocal (the extra bit that autoconf runs) anyway as this adds PKG_CONFIG path support to the configure script, which we do use in our configure script already. I don't understand the insistence on promoting the harder route either. |
“Insistence”? “harder”? 😄 I imagine README.md was originally written that way so as to act as documentation of which parts of the autotools the project is using. And aclocal.m4 would not have been originally listed as ignored because if it did appear (in a non-automake setup like htslib is) it should be consciously either
|
Aclocal does nothing if it finds nothing that needs adding. Here it is finding our use of PKG_CONFIG and so adding parameters to permit the user to adjust the bin and lib search paths, which isn't a bad thing. I'm not sure it actually works though as I've given it nothing more than a cursory glance. Thus the configure script we get differs if we use the prescribed route vs autoreconf route. |
Crossed-lines there. No, we shouldn't add auto-generated files. We don't add configure, and this falls into the same case. We do state it is something to ignore though. |
We're agreeing that there is a bug here; but aclocal.m4 is in a different category from configure. configure is generated from other files within the HTSlib distribution. Indeed it should not be checked in (in 2018; in the old days there was an argument for checking it in to control for different versions of autoconf). aclocal.m4 OTOH is a cache of m4 functions from outwith HTSlib, which at least in theory people might not have or might have borken versions of. (Compare samtools/samtools@30bc5e2's commit message.) So there are reasons to consider checking it in. |
Ok I finally get it. My mistake here was believing the m4 files in /usr/share/aclocal/ were bundled as part of aclocal, but they're not. That's /usr/share/aclocal-1.14 (for example). So yes, agreed the pkg.m4 script which gets put into aclocal.m4 should probably be checked in so it is included irrespective of whether someone has pkgconfig (although if not then frankly it won't work anyway, so we're down to the case of dealing with autoreconf on one system and ./configure on another). Anyway, this issue highlighted something interesting and a bug still. Thanks @ThomasHickman |
Having aclocal.m4 committed means that you end up with dirty builds. I sort of followed the above discussion, but didn't understand the conclusion. What benefit does it give anyone to provide a file that they will generate for themselves? |
This is a generated file from automake, so should be included in the
.gitignore
file.