building glib on win32 MSVC6

Dear All,

I've just managed to build glib-1.20 on windows with MS Visual C 6. I
accept your commiserations. But it went pretty well. The only problem I
found was with strtoll and strtoull for which I cannot find a MSVC6
equivalent. So I patched GType.xs to drop back to 32-bit, which
naturally causes the 64-bit tests to fail, but hey it could be a lot worse.

diff Glib-1.120/GType.xs /opt/mh/Windows/Temp/Glib-1.120/GType.xs
<     return strtoll (SvPV_nolen (sv), NULL, 10);
    #if defined(_MSC_VER) && _MSC_VER < 1300
        return strtol(SvPV_nolen(sv), NULL, 10);
        return strtoll (SvPV_nolen (sv), NULL, 10);
<     return strtoull (SvPV_nolen (sv), NULL, 10);
    #if defined(_MSC_VER) && _MSC_VER < 1300
        return strtoul(SvPV_nolen(sv), NULL, 10);
        return strtoull (SvPV_nolen (sv), NULL, 10);

I'm sure you guys can do a better job, but I'm happy :)


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