Search code examples
linuxmacosunixldunix-ar

How to detect library order for one pass linker?


Is there a tool that will analyze a large group of static archives, and order them for input to a one pass linker?


Solution

  • Is something like this what you're looking for...

     lorder statica.a staticb.a | tsort
    

    This will give you the list in the correct order.