Create Library
-
wrote on 25 Oct 2018, 00:01 last edited by
-
Hi,
I'm a computer science student, and I start to learn C, now I want to create a Library with a function, that I can include it in another project, but no kit appears, as shown in the attached image.
hi @Tiecker, welcome.
How did you install Qt and Creator? which version?
Do you have Xcode on your machine?
-
wrote on 29 Oct 2018, 21:54 last edited by
My version is QtCreator 4.8.0-beta1 (v4.7.82), and I have Xcode in my machine, for C projects, I can run the programs, but, creating a library a can't use the same kit.
-
wrote on 31 Oct 2018, 10:20 last edited by
@Tiecker perhaps its better if you start off by creating a library project by hand, or in the very least by configuring a build automation script without the help of an IDE.
I'm afraid Qt Developer's support for C is not exactly there in spite of supporting C compilers, and you'll end up either using qmake or cmake, which always require some level of manual configuration.
Here's a link to a stack overflow question that includes detailed answers on how to setup a cmake build for a shared library project. Most answers follow cmake's modern target-based style, which includes some degree of hand-holding, but it's very effective in getting a minimal working example.
1/4