[SPEC2DEF]
authorHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 10 Aug 2013 15:00:50 +0000 (15:00 +0000)
committerHermès Bélusca-Maïto <hermes.belusca-maito@reactos.org>
Sat, 10 Aug 2013 15:00:50 +0000 (15:00 +0000)
In GCC builds, LD sucks, and therefore, use NAME instead of LIBRARY to prevent that GNU crap from marking executables as dlls just because they export stuff, which is needed by both ntoskrnl and ntvdm.
Tested and approved by Aleksandar Aandrejevic a.k.a. [TheFlash], gigaherz and Amine Khaldi.
See:
http://msdn.microsoft.com/en-us/library/28d6s79h.aspx - "Module-Definition (.Def) Files"
http://msdn.microsoft.com/en-us/library/30fw19zw.aspx - For a description of the LIBRARY keyword
http://msdn.microsoft.com/en-us/library/03b3wfkt.aspx - For a description of the NAME keyword
http://sourceware.org/binutils/docs-2.16/binutils/def-file-format.html - "The format of the dlltool .def file" (GCC)
for more information.

svn path=/trunk/; revision=59686

reactos/tools/spec2def/spec2def.c

index e5cee3c..138f39d 100644 (file)
@@ -306,7 +306,7 @@ OutputHeader_def(FILE *file, char *libname)
 {
     fprintf(file,
             "; File generated automatically, do not edit!\n\n"
 {
     fprintf(file,
             "; File generated automatically, do not edit!\n\n"
-            "LIBRARY %s\n\n"
+            "NAME %s\n\n"
             "EXPORTS\n",
             libname);
 }
             "EXPORTS\n",
             libname);
 }