I have some projects that run on custom hardware.
Now the hardware has changed, which required some software changes.
Therefore, there is source A for “old hardware” and source B for “new hardware”, which are 95% the same.
If a new feature is added in the future, it has to be done for both versions. In other words, A und B will exist side by side and from now on will always require the same changes.
I have just started to use Subversion, therefore I am not very familiar with all the possibilities.
As I understand, a new branch for B would separate both from that point on, which is not what I need.
What is the best way to maintain A and B so that future changes will apply to both versions without having to manually apply them twice?
If possible, I’d maintain a single source tree and use #ifdefs to customize the code for the particular processor (assuming you’re using C or C++). This works especially well if you can isolate the parts that are hardware-dependent into a small number of files. If you can do this, no extra subversion magic is needed.