make: Archive Pitfalls

1 
1 11.3 Dangers When Using Archives
1 ================================
1 
1 It is important to be careful when using parallel execution (the '-j'
1 switch; ⇒Parallel Execution Parallel.) and archives.  If multiple
1 'ar' commands run at the same time on the same archive file, they will
1 not know about each other and can corrupt the file.
1 
1    Possibly a future version of 'make' will provide a mechanism to
1 circumvent this problem by serializing all recipes that operate on the
1 same archive file.  But for the time being, you must either write your
1 makefiles to avoid this problem in some other way, or not use '-j'.
1