summarylogtreecommitdiffstats
path: root/0014-mingwize-pkgdata.mingw.patch
blob: 968a42d096e5924ac4df55123441a6b4b8ca40b4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
diff -Naur icu-orig/source/tools/pkgdata/pkgdata.cpp icu/source/tools/pkgdata/pkgdata.cpp
--- icu-orig/source/tools/pkgdata/pkgdata.cpp	2016-06-15 21:58:17.000000000 +0300
+++ icu/source/tools/pkgdata/pkgdata.cpp	2018-03-01 10:09:24.760635900 +0300
@@ -893,21 +893,9 @@
     const char* FILE_EXTENSION_SEP = uprv_strlen(pkgDataFlags[SO_EXT]) == 0 ? "" : ".";
     const char* FILE_SUFFIX = pkgDataFlags[LIB_EXT_ORDER][0] == '.' ? "." : "";
 
-#if U_PLATFORM == U_PF_MINGW
-        /* MinGW does not need the library prefix when building in dll mode. */
-        if (IN_DLL_MODE(mode)) {
-            sprintf(libFileNames[LIB_FILE], "%s", libName);
-        } else {
-            sprintf(libFileNames[LIB_FILE], "%s%s%s",
-                    (strstr(libName, "icudt") ? "lib" : ""),
-                    pkgDataFlags[LIBPREFIX],
-                    libName);
-        }
-#else
         sprintf(libFileNames[LIB_FILE], "%s%s",
                 pkgDataFlags[LIBPREFIX],
                 libName);
-#endif
 
         if(o->verbose) {
           fprintf(stdout, "# libFileName[LIB_FILE] = %s\n", libFileNames[LIB_FILE]);
diff -Naur icu-orig/source/tools/pkgdata/pkgtypes.h icu/source/tools/pkgdata/pkgtypes.h
--- icu-orig/source/tools/pkgdata/pkgtypes.h	2016-06-15 21:58:17.000000000 +0300
+++ icu/source/tools/pkgdata/pkgtypes.h	2018-03-01 10:09:24.760635900 +0300
@@ -140,10 +140,10 @@
 # ifndef UDATA_SO_SUFFIX
 #  define UDATA_SO_SUFFIX ".dll"
 # endif
-# define LIB_PREFIX ""
-# define LIB_STATIC_PREFIX ""
-# define OBJ_SUFFIX ".obj"
-# define UDATA_LIB_SUFFIX ".lib"
+# define LIB_PREFIX "lib"
+# define LIB_STATIC_PREFIX "lib"
+# define OBJ_SUFFIX ".o"
+# define UDATA_LIB_SUFFIX ".a"
 
 #elif U_PLATFORM == U_PF_CYGWIN
 # define LIB_PREFIX "cyg"