static-libraries

Using static library in both App and Cocoa Touch Framework targets

纵然是瞬间 提交于 2019-12-11 02:28:31
问题 I've created a new "Cocoa Touch Framework" target called MyAppCore in my iPad project called MyApp , with the intention of putting some common code in there. Overall it works great, however, I've encountered problems with adding the static library provided by Google Analytics. I want to be able to use Google Analytics not only in the MyApp target, but inside of the MyAppCore target as well. In order to make both targets build, I have to link both targets with libGoogleAnalyticsServices.a.

Cannot find -lgfortran though gfortran is installed [duplicate]

心已入冬 提交于 2019-12-11 02:21:35
问题 This question already has answers here : Closed 7 years ago . Possible Duplicate: lgfortran not found I must admit that my question can be considered to be very similar to lgfortran not found, but as I am a newbie in Linux I need more help and I couldn't find what I am looking for in the above post. I have a fresh linux mint Debian edition installed and I am trying to make a lapack binding for Ada to work. If I check for gfortran, I get: gfortran-4.6 -v Using built-in specs. COLLECT_GCC

While using two static library in project, conflict due to class with same name compiled in both static libraries

可紊 提交于 2019-12-11 02:01:41
问题 I have implemented two static library having the following structure: FirstStaticLibrary.a BaseClass.h @interface BaseClass -some methods @end FirstDerivedClass.h @interface FirstDerivcedClass:BaseClass { } -some methods @end SecondStaticLibrary.a BaseClass.h @interface BaseClass -some methods; @end SecondDerivedClass.h @interface SecondDerivedClass:BaseClass { } -someMethods; @end Above two static library is having the common file BaseClass.h and BaseClass.m These static libraries are added

-fvisibility=hidden not passed by compiler for Debug builds

余生颓废 提交于 2019-12-11 00:44:34
问题 I am building a project in which I have enabled GCC_INLINES_ARE_PRIVATE_EXTERN and GCC_SYMBOLS_PRIVATE_EXTERN because I am consuming static libraries that were pre-built with those flags on. However, when I build my project for Debug -fvisibility=hidden is not included in the compiler flags, but it does get included when I build my project for Release. Is there any other flag that I need to turn on to make this happen? 回答1: This is old, but it it seems the conflict comes from the Enable

Dynamic library uses statics libraries, undefined symbols appears

♀尐吖头ヾ 提交于 2019-12-11 00:28:19
问题 I've look for a solutions to my trouble and just get some clues, but I could not find any consistent solution: I have the code of a dynamic library (libdyna.so), that uses the functions of 3 statics libraries (libone.a, libtwo.a, libthree.a) and the log4cpp library. And when I built it the first time everything looked fine, I could make the 'libdyna.so', but when y tested it with my java test program though a wrapper (the jni wrapper works fine) I got lots of undefined references. Then I put

Why some programs require both .lib and .dll to work…

半世苍凉 提交于 2019-12-10 23:30:05
问题 When I was going to set up my developing environment for (SDLSimple DirectMediaLayer) , I downloaded the package provided by the website, from the readme.txt file I found that I need both .lib and .dll ... My question is : I am not sure if my understanding is correct : in my thought, .lib for windows is like .a for linux , is static library , and .dll for windows is like .so for linux , is shared library , is this correct ? If the idea above is correct, I think we can only use .lib or .dll ,

Creating Cocoa Touch Static Library with XCode4

允我心安 提交于 2019-12-10 21:26:01
问题 When creating a Cocoa Touch Static Library with XCode4, the .a file in the Products groups appear red and building doesnt fix this. Then, when adding this project to another project in the same workspace with Build Phases/Link Binary With Libraries, the build fails at linking. Any pointers? Edit: It looks like a problem with anything I build with XCode4, because no matter what project I build, the content of Products appears in red. 回答1: I experienced the same bug in Xcode 4. Try building the

Linking GLFW on CLion with CMake

て烟熏妆下的殇ゞ 提交于 2019-12-10 20:03:17
问题 Does anyone know how to link glfw to a CLion project? CLion is based on CMake so if you have knowledge on CMake, you can help. What I want to do is, to put my dependencies into my project folder so when I push my code to git, others who download the code won't have to do any linking locally, the environment will be set up for them. I tried to moving the root folder of glfw to the project folder, but from then on, I have failed to successfully adjust my CMakelist.txt file to actually be able

link static library (without -fPIC) to shared library on 64bit OS

安稳与你 提交于 2019-12-10 18:13:20
问题 I write programm in c++, from which will be made shared library - and done it will be used by JNI. I have 3rd party library ( libexample.a ) and need to link it to shared library ( libshared.so ). The problem is, that I work on 64bit CentOS and -fPIC is needed to create shared lib, but 3rd party library wasnt compiled with -fPIC. Until building I recive: /usr/bin/ld: /home/tom/Project/src/libexample.a(SomeObject.o): relocation R_X86_64_32 against 'someData' can not be used when making a

gcc library option with a colon, -l:libevent.a

北城以北 提交于 2019-12-10 17:34:03
问题 I'm going through a Makefile. Found this interesting bit of code, LIBS = -l:libevent.a . Was digging through gcc documentation but didn't find anything relevant. Does anyone know what it means? 回答1: It instructs the linker to find and link a library with the exact name libevent.a , in the specified ( -Ldir ) or default linker search directories, as opposed to the usual convention whereby -lfoo instructs the linker to find and link either libfoo.so (shared library) or libfoo.a (static library)