diff options
author | Karl Berry <karl@freefriends.org> | 2010-05-31 18:39:11 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2010-05-31 18:39:11 +0000 |
commit | 48fe5a48abd086ba8a91aaa1cce61c22bc0baddd (patch) | |
tree | ba814334c00068c0d83cf7eb3d862369d51d680c /Build | |
parent | e896a66d2c84fc8a9af709c65743fe9cacab530a (diff) |
cast uint32 to placate aix, tlbuild 28 May 2010 15:23:25
git-svn-id: svn://tug.org/texlive/trunk@18654 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build')
3 files changed, 52 insertions, 5 deletions
diff --git a/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/ChangeLog b/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/ChangeLog index 9412f5a9719..2fd51d15ec7 100644 --- a/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/ChangeLog +++ b/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/ChangeLog @@ -1,6 +1,10 @@ 2010-05-31 Karl Berry <karl@tug.org> - * patch-09-unistd. + * Added patch-07-libdvisvgm-uint32. + * src/FontEngine.cpp: must cast &glyphindex to (FT_Uint *) + for AIX compiler (tlbuild 28 May 2010 15:23:25). + + Added patch-09-unistd. * src/FileSystem.cpp: unconditionally include <unistd.h>. (Needed on AIX, tlbuild 28 May 2010 15:08:06.) diff --git a/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/patch-07-libdvisvgm-uint32 b/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/patch-07-libdvisvgm-uint32 new file mode 100644 index 00000000000..0a194d96149 --- /dev/null +++ b/Build/source/texk/dvisvgm/dvisvgm-0.8.7-PATCHES/patch-07-libdvisvgm-uint32 @@ -0,0 +1,37 @@ +Index: FontEngine.cpp +=================================================================== +--- FontEngine.cpp (revision 18651) ++++ FontEngine.cpp (working copy) +@@ -59,11 +59,15 @@ + * @param[out] reverseMap the resulting map */ + static void build_reverse_map (FT_Face face, map<UInt32, UInt32> &reverseMap) { + UInt32 glyphIndex; +- UInt32 charcode = FT_Get_First_Char(face, &glyphIndex); ++ /* The explicit cast is necessary with the AIX compiler, ++ which considers the dvisvgm definition signed, ++ and incompatible with the freetype definition. */ ++ UInt32 charcode = FT_Get_First_Char(face, (FT_UInt *) &glyphIndex); + while (glyphIndex) { + // if (reverseMap.find(glyphIndex) == reverseMap.end()) + reverseMap[glyphIndex] = charcode; +- charcode = FT_Get_Next_Char(face, charcode, &glyphIndex); ++ charcode = FT_Get_Next_Char(face, charcode, ++ (FT_UInt *) &glyphIndex); + } + } + +@@ -112,10 +116,12 @@ + + FT_Set_Charmap(_currentFace, unicodeMap); + UInt32 glyphIndex; +- UInt32 charcode = FT_Get_First_Char(_currentFace, &glyphIndex); ++ UInt32 charcode = FT_Get_First_Char(_currentFace, ++ (FT_UInt *) &glyphIndex); + while (glyphIndex) { + translationMap[reverseMap[glyphIndex]] = charcode; +- charcode = FT_Get_Next_Char(_currentFace, charcode, &glyphIndex); ++ charcode = FT_Get_Next_Char(_currentFace, charcode, ++ (FT_UInt *) &glyphIndex); + } + FT_Set_Charmap(_currentFace, customMap); + } diff --git a/Build/source/texk/dvisvgm/dvisvgm-0.8.7/src/FontEngine.cpp b/Build/source/texk/dvisvgm/dvisvgm-0.8.7/src/FontEngine.cpp index 38acd1e73bb..be9bddb7fbc 100644 --- a/Build/source/texk/dvisvgm/dvisvgm-0.8.7/src/FontEngine.cpp +++ b/Build/source/texk/dvisvgm/dvisvgm-0.8.7/src/FontEngine.cpp @@ -59,11 +59,15 @@ void FontEngine::setDeviceResolution (int x, int y) { * @param[out] reverseMap the resulting map */ static void build_reverse_map (FT_Face face, map<UInt32, UInt32> &reverseMap) { UInt32 glyphIndex; - UInt32 charcode = FT_Get_First_Char(face, &glyphIndex); + /* The explicit cast is necessary with the AIX compiler, + which considers the dvisvgm definition signed, + and incompatible with the freetype definition. */ + UInt32 charcode = FT_Get_First_Char(face, (FT_UInt *) &glyphIndex); while (glyphIndex) { // if (reverseMap.find(glyphIndex) == reverseMap.end()) reverseMap[glyphIndex] = charcode; - charcode = FT_Get_Next_Char(face, charcode, &glyphIndex); + charcode = FT_Get_Next_Char(face, charcode, + (FT_UInt *) &glyphIndex); } } @@ -112,10 +116,12 @@ void FontEngine::buildTranslationMap (map<UInt32, UInt32> &translationMap) const FT_Set_Charmap(_currentFace, unicodeMap); UInt32 glyphIndex; - UInt32 charcode = FT_Get_First_Char(_currentFace, &glyphIndex); + UInt32 charcode = FT_Get_First_Char(_currentFace, + (FT_UInt *) &glyphIndex); while (glyphIndex) { translationMap[reverseMap[glyphIndex]] = charcode; - charcode = FT_Get_Next_Char(_currentFace, charcode, &glyphIndex); + charcode = FT_Get_Next_Char(_currentFace, charcode, + (FT_UInt *) &glyphIndex); } FT_Set_Charmap(_currentFace, customMap); } |