[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Automake 1.14 and subdir-objects
From: |
David Beer |
Subject: |
Automake 1.14 and subdir-objects |
Date: |
Thu, 24 Jul 2014 14:09:27 -0600 |
All,
I am currently trying to get our project completely compatible with
automake 1.14. We have multiple places where we compile a source file from
another of the project's subdirectories in a given subdirectory. The two
main use cases are:
1. To recompile a source file with different preprocessor variables
2. To execute the unit tests (we use the check framework).
When I attempted to build the project using automake 1.14, it would warn me
that subdir-objects wasn't enabled and would fail to build. After enabling
subdir-objects, it broke use case 1 because since the .o already existed it
didn't get re-built with the distinct preprocessor variables. I resolved
this by duplicating the files (there were only a few) and removing the
preprocessor logic. This wasn't my first choice but I didn't know another
way.
Scenario 2 is proving more difficult. It seems that the .deps/*.Plo files
aren't always generated by the original compile, and the option to run the
unit tests doesn't create it because it already finds the .o file.
So my questions:
Is it possible to get the old behavior prior to 1.14 where it would allow
me to use a source file from a different subdirectory and simply recompile
it into the directory that is currently building? It would be really nice
if I could achieve the old behavior but I haven't found any options to do
so to this point.
Is it possible for me to get the unit tests to work? I'm not going to
duplicate the source files in every one of their unit testing directories.
Should I be doing this a different way? Is this hard to get working because
something is being done wrong? I inherited the build structure of this
project and I'm no autotools expert myself, so I understand the possibility
that this might be a non-ideal way.
--
David Beer | Senior Software Engineer
Adaptive Computing
- Automake 1.14 and subdir-objects,
David Beer <=