Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to rename library .a product file name in Xcode 8?

I downloaded the following repository from GitHub:

https://github.com/zwaap/hello-int-pinvoke/tree/master/src/HelloInt.Native

I tried renaming my project to something with "lib" in the name by clicking on the project name and renaming it. Xcode asked me if I wanted to rename everything. I did so. Now the .a file under "Projects" has the prefix "liblib" in front it. I think Xcode automatically adds "lib" in front of .a files that it builds, but for some reason because I added "lib" to the project name no matter what I try to rename it to now the "lib" prefix is added twice.

Clicking on the product's file name doesn't help as it doesn't allow me to modify it there. I have tried doing it within "Manage Schemes" but double clicking on Targets there doesn't help either.

Is there a way to fix this without having to manually edit the project files with a text editor?

like image 441
gonzobrains Avatar asked Dec 03 '25 01:12

gonzobrains


1 Answers

Target > Packaging > Executable Prefix > "lib" to "" or the first part you want on the library

Target > Packaging > Product Name > "nameyouwant"

Output library "ExecutablePrefix"+"ProductName"+".a"

like image 115
Alfonso Nava Avatar answered Dec 04 '25 17:12

Alfonso Nava



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!