This question is surely answered here somewhere, but I couldn’t find it. I’ve been writing Java for over a decade now and my C experience was on Unix, so I’m kinda at square one here. In my Unix experience, someone else wrote the makefile and it just worked.
I have downloaded the C source code for libtar-1.2.11 from feep and ran make on it from inside of cygwin. This created a .a file and a .exe file. The EXE file appears to essentially be tar to run on Windows, but what I wanted was for the libraries to read and process the file in my own code.
If I remember correctly, those should be in the .a file (archive??) and this needs to be linked into a library that I can use from my C++ program. So I’m looking for a way to do that.
I am writing a library that will use a .tgz file and so I want to use this library. I think I’d like to turn libtar into a DLL as well as create a DLL myself for use in other languages.
So, how do I turn my .a file into something usable by other apps, and how do I access it from inside my code?
The generated
libmylib.ais actually an archive of all*.oforlibtar-1.2.11.you can verify this by doing
nm libmylib.a, it will print all the*.ofiles.Write your code, and link:
You generated this with cygwin, you can’t generate a dll out of that as far as i know.