[Easytag-mailing] Small nit in 2.1.2 compile



Nice to finally have gotten Easytag-2.x to compile and run after using the
-1.x version since a long time back.  Lots and lots of nice looking (GUI),
usability, and file support improvements from 1.x to 2.1.2.
Keep up the GREAT work!

Only ran into one small compilation nit along the way; may be that I'm
using somewhat antiquated gcc-3.2.2.  Here's the compile error I got:
easytag.c:4476:1: directives may not be used inside a macro argument
easytag.c:4475:15: unterminated argument list invoking macro "_"
easytag.c: In function `Display_Usage':
easytag.c:4479: `_' undeclared (first use in this function)
easytag.c:4479: (Each undeclared identifier is reported only once
easytag.c:4479: for each function it appears in.)
easytag.c:4479: parse error before string constant
make[3]: *** [easytag.o] Error 1
I'm including a `diff -u` patch file showing what I changed to fix it; hopefully
a general change that should be more portable and IMHO improves readability
just a bit.  {attach: xpatch.txt}  Caution: I didn't compile the change on WIN32
to verify compile didn't break there, but me thinks it should be Ok for WIN32
as well as under linux gcc-3.2.2 now.

Regards,
-SteveR
-----

--- easytag.c~	2007-07-10 01:15:47.000000000 -0500
+++ easytag.c	2007-07-22 16:19:36.000000000 -0500
@@ -4457,6 +4457,11 @@
     return (_("Unknown signal"));
 }
 
+#ifdef WIN32
+#define xPREFIX "c:"
+#else
+#define xPREFIX
+#endif
 
 /*
  * Display usage informations
@@ -4473,17 +4478,13 @@
               "\n"
               "Directory:\n"
               "----------\n"
-#ifdef WIN32
-              "c:/path_to/files  Use an absolute path to load,\n"
-#else
-              "/path_to/files    Use an absolute path to load,\n"
-#endif
+              xPREFIX "/path_to/files  Use an absolute path to load,\n"
               "path_to/files     Use a relative path.\n"
               "\n"));
     exit(0);
 }
 
-
+#undef xPREFIX
 
 /*
  * Exit the program


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]