right way to add a library to src/

Mihir Luthra 1999mihir.luthra at gmail.com
Sat Feb 8 02:54:40 UTC 2020


> Without taking a closer look, I think there is only one other file that is
> shared between darwintrace and pextlib. Unfortunately, there is no good
> solution
> to this in the current structure. What it currently does is to copy the
> *.c file
> around during compilation, but I think this is a really horrible
> workaround.


> I think the better option would be to have a new subdirectory for a
> library with
> the shared code that is then linked (statically) into both darwintrace and
> pextlib.
>

Yes, doing that with a static library was the final solution.

Meanwhile, I tried many ways to somehow get it working using a shared
library, maybe because with shared lib things were much clean and compact.
But the issue was darwintrace code would intercept sys calls in our shared
library as well which would make things even more complicated and slower.

Thanks,
Mihir
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.macports.org/pipermail/macports-dev/attachments/20200208/8173f4b1/attachment.html>


More information about the macports-dev mailing list