Re: Help: how to export function using makefile in mingw
Eli Zaretskii <eliz-mXXj517/[email protected]> Wed, 11 Mar 2015 17:58:16 +0200
| Newsgroups | gmane.comp.gnu.mingw.user,gmane.comp.gnu.mingw.msys |
|---|---|
| Message-ID | <[email protected]> |
> Date: Wed, 11 Mar 2015 16:27:10 +0800 > From: "[email protected]" <[email protected]> > > i compile a exe file, i want to export some functions. > > the code is : > > #define LIBIMOBILEDEVICE_API __declspec( dllexport ) > > LIBIMOBILEDEVICE_API void print_usage(int argc, char **argv) > { > char *name = NULL; > > name = strrchr(argv[0], '/'); > printf("Usage: %s [OPTIONS] [UDID]\n", (name ? name + 1: argv[0])); > printf("Prints device name or a list of attached devices.\n\n"); > printf(" The UDID is a 40-digit hexadecimal number of the device\n"); > printf(" for which the name should be retrieved.\n\n"); > printf(" -l, --list\t\tlist UDID of all attached devices\n"); > printf(" -d, --debug\t\tenable communication debugging\n"); > printf(" -h, --help\t\tprints usage information\n"); > printf("\n"); > printf("Homepage: <http://libimobiledevice.org>\n"); > } > > i run make command, the exe file export nothing. > > i write a simple code, using __declspec( dllexport ), then run gcc, the exe > have export function. > > i want to know how to export functions using makefile . You need to tell us more. What do you mean by "export some function", and how do you know that "the exe file exports nothing"? Also, what command(s) did your makefile run? More importantly, what do you want to do with this code, once you solve your export problem (if there is one)? ------------------------------------------------------------------------------ Dive into the World of Parallel Programming The Go Parallel Website, sponsored by Intel and developed in partnership with Slashdot Media, is your hub for all things parallel software development, from weekly thought leadership blogs to news, videos, case studies, tutorials and more. Take a look and join the conversation now. http://goparallel.sourceforge.net/ _______________________________________________ MinGW-users mailing list [email protected] This list observes the Etiquette found at http://www.mingw.org/Mailing_Lists. We ask that you be polite and do the same. Disregard for the list etiquette may cause your account to be moderated. _______________________________________________ You may change your MinGW Account Options or unsubscribe at: https://lists.sourceforge.net/lists/listinfo/mingw-users Also: mailto:mingw-users-request-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org?subject=unsubscribe