#
290803 |
|
13-Nov-2015 |
bdrewery |
META MODE: Don't double stage SYMLINKS for shared libraries.
This also fixes truncating the path that the links were installed to, which was most likely going to be the same directory the library was in anyhow.
Let bsd.sys.mk handle SYMLINKS via stage_symlinks. stage_libs continues to handle the SHLIB_LINK though since it is not a SYMLINKS.
This fixes a race, seen easily in lib/libthr, where libpthread_p.a is created by both stage_libs and stage_symlinks resulting in 'ln: File exists'.
Sponsored by: EMC / Isilon Storage Division Discussed with: sjg
|
#
288475 |
|
02-Oct-2015 |
bdrewery |
META_MODE: Fix stage_links not running in the right order without -j.
This fixes staging errors for non-parallel builds that have LINKS.
Creating hardlinks must always happen after the actual files are installed. The staging code was protected by an .ORDER statement that only affected parallel -j builds but not non-parallel builds. Fix this by making the real stage_links.SET (stage_links.links, stage_links.mlinks, etc) targets depend on the main targets for all of the other possible staging needs. For example, stage_links.links will depend on stage_as and stage_files, which have their own dependencies to stage_as.prog or stage_files.prog or stage_files.SET, which is enough to satistfy the ordering.
Also remove the requirement that symlinks be created last, as they can safely be made without the source being present unlike hardlinks. This also fixes symlinks to come before hardlinks as it is possible, in theory, to hardlink a symlink. This is not actually supported here though.
Sponsored by: EMC / Isilon Storage Division
|