I have a repository for one of my projects that has a nested repository using the svn:externals
property to update files from an external library. The problem is that I need to comment out one of the function declarations from one of the headers in this library, and carry around the modified header with the root repository.
Is there a way that this could be done, so that when the library is updated, it overrides that specific file with my version of it?
There isn't a built in feature to help you with this.
The general practice way of dealing with this would be: Make a branch of the library you're using then make the changes you need there and use the newly created branch as the external for the root project. In my experience I've found this to be a simple and effective solution to the problem you describe.
What you want sounds like a "vendor branch" scenario to me.
current repository
suggested repository
How to create the layout
Create ^/vendor/library/current and DOWNLOAD the original unmodified library code into it.
modify ^/myproject/library and commit
How to update the library without losing your modifications
Download the latest original release of the library into ^/vendor/library/current OVERWRITING files.
profit
Instead of branching "current" directly into your project you could branch to a "my-modified-libs" directory and make use of it via externals. This would be advised if you have multiple projects that need the same modified version of a library.
Keep in mind that vendor branches will have problems dealing with renames and deletes as those can not be tracked by overwriting. Cross-repository merging is a different and rather young topic for SVN.
If you try it out, give us feedback how it went :)
Christoph