New package: qemacs-0.4.0.20140809

This commit is contained in:
Christian Neukirchen 2015-03-23 16:02:23 +01:00
parent a4dddaa508
commit c74b6d4416
2 changed files with 63 additions and 0 deletions

View File

@ -0,0 +1,31 @@
diff --git tty.c tty.c
index bff0a97..21287a4 100644
--- tty.c
+++ tty.c
@@ -95,7 +95,6 @@ typedef struct TTYState {
/* input handling */
enum InputState input_state;
int input_param;
- int utf8_state;
int utf8_index;
unsigned char buf[10];
char *term_name;
@@ -413,12 +412,14 @@ static void tty_read_handler(void *opaque)
/* charset handling */
if (s->charset == &charset_utf8) {
- if (ts->utf8_state == 0) {
- const char *p = cs8(ts->buf);
+ /* Make sure utf8 input works correctly 20040314 <damm@opensource.se> */
+ ts->utf8_index++;
+ if (utf8_length[ts->buf[0]] == ts->utf8_index) {
+ const char *p;
+ p = (const char *)ts->buf;
ch = utf8_decode(&p);
- } else {
- ts->utf8_state = utf8_length[ts->buf[0]] - 1;
ts->utf8_index = 0;
+ } else {
return;
}
} else {

32
srcpkgs/qemacs/template Normal file
View File

@ -0,0 +1,32 @@
# Template file for 'qemacs'
pkgname=qemacs
version=0.4.0.20140809
revision=1
wrksrc="${pkgname}"
build_style=configure
configure_args="--prefix=/usr --mandir=/usr/share/man
--disable-x11 --disable-plugins"
hostmakedepends="cvs"
short_desc="Small but powerful Emacs clone (feat. UTF-8, HTML, shell, dired)"
maintainer="Christian Neukirchen <chneukirchen@gmail.com>"
license="LGPL-2.1"
homepage="http://bellard.org/qemacs/"
do_fetch() {
cvs -d :pserver:anonymous@cvs.savannah.nongnu.org:/sources/qemacs \
co -D ${version##*.} qemacs
}
do_build() {
sed -i -e /HOST_CC/s/CFLAGS/HOST_CFLAGS/ -e /INSTALL/s/-s// \
Makefile */Makefile
echo CONFIG_HTML=yes >>config.mak
make V=1 TARGETS=qe STRIP=echo CC="$CC" \
CFLAGS="$CFLAGS -funsigned-char -Ilibqhtml -I.." \
LDFLAGS="$LDFLAGS"
}
do_install() {
make TARGETS=qe DESTDIR="$DESTDIR" CONFIG_HTML= install
vdoc qe-doc.html
}