Static Library using frameworks in specific projects

前端 未结 4 1359
时光说笑
时光说笑 2020-12-14 02:39

I have created a static library containing all my generic classes. Some of these classes use frameworks.

Now I have two projects, one that uses some classes that us

4条回答
  •  情书的邮戳
    2020-12-14 03:01

    A static library is built before your app is compiled, and then the whole thing is linked into your app. There's no way to include some parts of the library but not others -- you get the whole enchilada.

    Since you have the source code for the library, why not just add the code directly to each application? That way you can control exactly what goes into each app. You can still keep your generic classes together in the same location, and use the same code in both apps, but you avoid the hassle of using a library.

提交回复
热议问题