Revision: 139574 https://trac.macports.org/changeset/139574 Author: sean@macports.org Date: 2015-08-20 17:57:03 -0700 (Thu, 20 Aug 2015) Log Message: ----------- emacs-mac-app: update to 5.9 and add patch to support ligatures Modified Paths: -------------- trunk/dports/aqua/emacs-mac-app/Portfile Added Paths: ----------- trunk/dports/aqua/emacs-mac-app/files/patch-src_composite.c.diff Modified: trunk/dports/aqua/emacs-mac-app/Portfile =================================================================== --- trunk/dports/aqua/emacs-mac-app/Portfile 2015-08-21 00:57:03 UTC (rev 139573) +++ trunk/dports/aqua/emacs-mac-app/Portfile 2015-08-21 00:57:03 UTC (rev 139574) @@ -4,8 +4,7 @@ PortSystem 1.0 name emacs-mac-app -version 5.7 -revision 1 +version 5.9 categories aqua editors maintainers hum openmaintainer @@ -22,7 +21,7 @@ fetch.type git git.url http://www.math.s.chiba-u.ac.jp/~mituharu/emacs-mac.git -git.branch f1161b7d871e4d022376649a0f74f5b4211c234c +git.branch 4f16f12a23fd34148f8e161d6a08a1d8b4674294 depends_lib port:ncurses \ port:libxml2 \ @@ -31,7 +30,8 @@ depends_build port:autoconf port:automake port:libtool -patchfiles patch-src_emacs.c.diff +patchfiles patch-src_emacs.c.diff \ + patch-src_composite.c.diff universal_variant no Added: trunk/dports/aqua/emacs-mac-app/files/patch-src_composite.c.diff =================================================================== --- trunk/dports/aqua/emacs-mac-app/files/patch-src_composite.c.diff (rev 0) +++ trunk/dports/aqua/emacs-mac-app/files/patch-src_composite.c.diff 2015-08-21 00:57:03 UTC (rev 139574) @@ -0,0 +1,60 @@ +diff --git a/src/composite.c b/src/composite.c +index d158f04..55e7faa 100644 +--- src/composite.c.orig ++++ src/composite.c +@@ -1755,25 +1755,49 @@ should be ignored. */) + + if (NILP (string)) + { +- if (NILP (BVAR (current_buffer, enable_multibyte_characters))) +- error ("Attempt to shape unibyte text"); + validate_region (&from, &to); + frompos = XFASTINT (from); + topos = XFASTINT (to); +- frombyte = CHAR_TO_BYTE (frompos); ++ if (!NILP (BVAR (current_buffer, enable_multibyte_characters))) ++ frombyte = CHAR_TO_BYTE (frompos); ++ else ++ { ++ ptrdiff_t pos; ++ ++ /* fill_gstring_header below uses ++ FETCH_CHAR_ADVANCE_NO_CHECK that assumes the current ++ buffer is multibyte, but it is safe as long as it only ++ fetches ASCII chars. */ ++ for (pos = frompos; pos < topos; pos++) ++ if (!ASCII_BYTE_P (*(BYTE_POS_ADDR (pos)))) ++ error ("Attempt to shape non-ASCII part of unibyte text"); ++ frombyte = frompos; ++ } + } + else + { + CHECK_NATNUM (from); + CHECK_NATNUM (to); + CHECK_STRING (string); +- if (! STRING_MULTIBYTE (string)) +- error ("Attempt to shape unibyte text"); + if (! (XINT (from) <= XINT (to) && XINT (to) <= SCHARS (string))) + args_out_of_range_3 (string, from, to); + frompos = XFASTINT (from); + topos = XFASTINT (to); +- frombyte = string_char_to_byte (string, frompos); ++ if (STRING_MULTIBYTE (string)) ++ frombyte = string_char_to_byte (string, frompos); ++ else ++ { ++ ptrdiff_t pos; ++ ++ /* fill_gstring_header below uses ++ FETCH_STRING_CHAR_ADVANCE_NO_CHECK that assumes the ++ string is multibyte, but it is safe as long as it only ++ fetches ASCII chars. */ ++ for (pos = frompos; pos < topos; pos++) ++ if (!ASCII_BYTE_P (SREF (string, pos))) ++ error ("Attempt to shape non-ASCII part of unibyte text"); ++ frombyte = frompos; ++ } + } + + header = fill_gstring_header (Qnil, frompos, frombyte,
participants (1)
-
sean@macports.org