diff options
-rw-r--r-- | ChangeLog | 18 | ||||
-rw-r--r-- | anaconda.spec | 2 | ||||
-rw-r--r-- | isys/Makefile | 2 | ||||
-rw-r--r-- | isys/isys.c | 8 | ||||
-rw-r--r-- | isys/lang.c | 36 | ||||
-rw-r--r-- | isys/lang.h | 1 | ||||
-rw-r--r-- | lang-table | 8 | ||||
-rw-r--r-- | language.py | 4 | ||||
-rw-r--r-- | loader2/Makefile | 16 | ||||
-rw-r--r-- | loader2/lang.c | 20 | ||||
-rw-r--r-- | stubs/Makefile | 2 | ||||
-rw-r--r-- | stubs/unicode-lite.c | 23 | ||||
-rw-r--r-- | text.py | 20 | ||||
-rw-r--r-- | textw/language_text.py | 32 |
14 files changed, 41 insertions, 151 deletions
@@ -1,3 +1,21 @@ +2006-02-22 Jeremy Katz <katzj@redhat.com> + + * lang-table: Set all previously bterm using languages to "none" + for the fact that we can't handle them in text-mode anymore + * textw/language_text.py (LanguageWindow.__call__): Remove bterm + special-casing. + * text.py (InstallInterface.run): Likewise. + * loader2/lang.c (setupLanguage): Likewise. + * language.py (Language.fixLang): No more "bterm" font + * stubs/unicode-lite.c: Don't require wlite + * stubs/Makefile: Don't link against wlite + * loader2/Makefile: No more linking to bterm here either + * isys/lang.c: Remove bterm support code. + * isys/lang.h: And declaration. + * isys/Makefile (LOADLIBES): No more linking to bterm + * isys/isys.c (start_bterm): Remove this + * anaconda.spec (BuildPreReq): Bye-bye bogl + 2006-02-22 Peter Jones <pjones@redhat.com> * iw/bootloader_main_gui.py (MainBootLoaderWindow): Don't use diff --git a/anaconda.spec b/anaconda.spec index edf942d02..5b2acd4a7 100644 --- a/anaconda.spec +++ b/anaconda.spec @@ -5,7 +5,7 @@ License: GPL Summary: Graphical system installer Group: Applications/System Source: anaconda-%{PACKAGE_VERSION}.tar.bz2 -BuildPreReq: pump-devel >= 0.8.20, kudzu-devel >= 1.2.0, pciutils-devel, bzip2-devel, e2fsprogs-devel, python-devel gtk2-devel rpm-python >= 4.2-0.61, newt-devel, rpm-devel, gettext >= 0.11, rhpl, booty, libxml2-python, zlib-devel, bogl-devel >= 0:0.1.9-17, bogl-bterm >= 0:0.1.9-17, elfutils-devel, beecrypt-devel, libselinux-devel >= 1.6, libX11-devel, libXxf86misc-devel, intltool >= 0.31.2-3, python-urlgrabber, pykickstart, yum, device-mapper >= 1.01.05-3, libsepol-devel, pango-devel, pirut, libXt-devel +BuildPreReq: pump-devel >= 0.8.20, kudzu-devel >= 1.2.0, pciutils-devel, bzip2-devel, e2fsprogs-devel, python-devel gtk2-devel rpm-python >= 4.2-0.61, newt-devel, rpm-devel, gettext >= 0.11, rhpl, booty, libxml2-python, zlib-devel, elfutils-devel, beecrypt-devel, libselinux-devel >= 1.6, libX11-devel, libXxf86misc-devel, intltool >= 0.31.2-3, python-urlgrabber, pykickstart, yum, device-mapper >= 1.01.05-3, libsepol-devel, pango-devel, pirut, libXt-devel Requires: rpm-python >= 4.2-0.61, rhpl >= 0.170, parted >= 1.6.3-7, booty, kudzu > 1.2.0, yum >= 2.5.1-3, pirut Requires: pyparted, libxml2-python, python-urlgrabber Requires: system-logos, pykickstart diff --git a/isys/Makefile b/isys/Makefile index 626ffc428..ae8c37ac2 100644 --- a/isys/Makefile +++ b/isys/Makefile @@ -8,7 +8,7 @@ OBJECTS = nfsmount.o nfsmount_clnt.o nfsmount_xdr.o imount.o getmacaddr.o \ ethtool.o getipaddr.o wireless.o eddsupport.o SOBJECTS = $(patsubst %.o,%.lo,$(OBJECTS)) SOURCES = $(patsubst %.o,%.c,$(OBJECTS)) isys.c -LOADLIBES = -lresolv -lpci -lpopt -lpump -lext2fs -lz -lbterm -lbogl -lwlite -lkudzu -lpci -ldevmapper -lselinux -lsepol +LOADLIBES = -lresolv -lpci -lpopt -lpump -lext2fs -lz -lkudzu -lpci -ldevmapper -lselinux -lsepol PYMODULES = _isys.so SUBDIRS = gzlib DIET = diet diff --git a/isys/isys.c b/isys/isys.c index ac16705cf..bb1073200 100644 --- a/isys/isys.c +++ b/isys/isys.c @@ -107,7 +107,6 @@ static PyObject * doGetPageSize(PyObject * s, PyObject * args); static PyObject * py_bind_textdomain_codeset(PyObject * o, PyObject * args); static PyObject * getLinkStatus(PyObject * s, PyObject * args); static PyObject * hasIdeRaidMagic(PyObject * s, PyObject * args); -static PyObject * start_bterm(PyObject * s, PyObject * args); static PyObject * py_getDasdPorts(PyObject * s, PyObject * args); static PyObject * py_isUsableDasd(PyObject * s, PyObject * args); static PyObject * py_isLdlDasd(PyObject * s, PyObject * args); @@ -167,7 +166,6 @@ static PyMethodDef isysModuleMethods[] = { { "bind_textdomain_codeset", (PyCFunction) py_bind_textdomain_codeset, METH_VARARGS, NULL}, { "getLinkStatus", (PyCFunction) getLinkStatus, METH_VARARGS, NULL }, { "hasIdeRaidMagic", (PyCFunction) hasIdeRaidMagic, METH_VARARGS, NULL }, - { "startBterm", (PyCFunction) start_bterm, METH_VARARGS, NULL }, { "getDasdPorts", (PyCFunction) py_getDasdPorts, METH_VARARGS, NULL}, { "isUsableDasd", (PyCFunction) py_isUsableDasd, METH_VARARGS, NULL}, { "isLdlDasd", (PyCFunction) py_isLdlDasd, METH_VARARGS, NULL}, @@ -1474,12 +1472,6 @@ static PyObject * hasIdeRaidMagic(PyObject * s, PyObject * args) { #endif } -static PyObject * start_bterm(PyObject * s, PyObject * args) { - if (!PyArg_ParseTuple(args, "")) return NULL; - - return Py_BuildValue("i", isysStartBterm()); -} - static PyObject * doProbeBiosDisks(PyObject * s, PyObject * args) { if (!PyArg_ParseTuple(args, "")) return NULL; diff --git a/isys/lang.c b/isys/lang.c index 4625a6b51..cacce4fe7 100644 --- a/isys/lang.c +++ b/isys/lang.c @@ -183,39 +183,3 @@ int isysLoadKeymap(char * keymap) { return rc; } - -/* returns 0 on success, 1 on failure */ -extern int bterm_main(int argc, char **argv); - -int isysStartBterm(void) { - char * btermargs[4] = { "bterm", "-s", "-f", NULL }; - int rc; - struct stat sb; - - /* if we've already successfully started bterm, we don't need to again */ - if (!access("/var/run/bterm.run", R_OK)) - return 0; - - /* assume that if we're already on a pty we can handle unicode */ - fstat(0, &sb); - if (major(sb.st_rdev) == 3 || major(sb.st_rdev) == 136) - return 0; - - if (!access("/usr/lib/bogl/font.bgf.gz", R_OK)) - btermargs[3] = "/usr/lib/bogl/font.bgf.gz"; - else if (!access("/etc/font.bgf.gz", R_OK)) - btermargs[3] = "/etc/font.bgf.gz"; - else if (!access("font.bgf.gz", R_OK)) - btermargs[3] = "font.bgf.gz"; - else - return 1; - - rc = bterm_main(4, btermargs); - - if (!rc) { - int fd = open("/var/run/bterm.run", O_CREAT | O_TRUNC | O_RDWR, 0600); - close(fd); - } - - return rc; -} diff --git a/isys/lang.h b/isys/lang.h index 2fd6c1c5b..55e5769a1 100644 --- a/isys/lang.h +++ b/isys/lang.h @@ -21,6 +21,5 @@ int loadKeymap(gzFile stream); int isysLoadFont(void); int isysLoadKeymap(char * keymap); int isysSetUnicodeKeymap(void); -int isysStartBterm(void); #endif diff --git a/lang-table b/lang-table index 7125ba05f..21d32f600 100644 --- a/lang-table +++ b/lang-table @@ -5,8 +5,8 @@ Bengali bn none bn_BD.UTF-8 us Asia/Dhaka Bengali(India) bn none bn_IN.UTF-8 us Asia/Calcutta Bulgarian bg latarcyrheb-sun16 bg_BG.UTF-8 bg Europe/Sofia Catalan ca latarcyrheb-sun16 ca_ES.UTF-8 es Europe/Madrid -Chinese(Simplified) zh_CN bterm zh_CN.UTF-8 us Asia/Shanghai -Chinese(Traditional) zh_TW bterm zh_TW.UTF-8 us Asia/Taipei +Chinese(Simplified) zh_CN none zh_CN.UTF-8 us Asia/Shanghai +Chinese(Traditional) zh_TW none zh_TW.UTF-8 us Asia/Taipei Croatian hr latarcyrheb-sun16 hr_HR.UTF-8 croat Europe/Zagreb Czech cs latarcyrheb-sun16 cs_CZ.UTF-8 cz-lat2 Europe/Prague Danish da latarcyrheb-sun16 da_DK.UTF-8 dk Europe/Copenhagen @@ -22,8 +22,8 @@ Hungarian hu latarcyrheb-sun16 hu_HU.UTF-8 hu Europe/Budapest Icelandic is latarcyrheb-sun16 is_IS.UTF-8 is-latin1 Atlantic/Reykjavik Indonesian id latarcryheb-sun16 id_ID.UTF-8 us Asia/Jakarta Italian it latarcyrheb-sun16 it_IT.UTF-8 it Europe/Rome -Japanese ja bterm ja_JP.UTF-8 jp106 Asia/Tokyo -Korean ko bterm ko_KR.UTF-8 us Asia/Seoul +Japanese ja none ja_JP.UTF-8 jp106 Asia/Tokyo +Korean ko none ko_KR.UTF-8 us Asia/Seoul Macedonian mk latarcyrheb-sun16 mk_MK.UTF-8 mk Europe/Skopje Malay ms latarcyrheb-sun16 ms_MY.UTF-8 us Asia/Kuala_Lumpur Norwegian nb latarcyrheb-sun16 nb_NO.UTF-8 no Europe/Oslo diff --git a/language.py b/language.py index b9ab4aa6a..aaaac7319 100644 --- a/language.py +++ b/language.py @@ -122,7 +122,7 @@ class Language: for lang in self.localeInfo.keys(): if lang == langToFix: (a, b, font, c, d) = self.localeInfo[lang] - if font == "bterm" or font == "none": + if font == "none": ret = "en_US.UTF-8" self.targetLang = lang @@ -141,7 +141,7 @@ class Language: # Note: in /etc/fonts.cgz fonts are named by the map # name as that's unique, font names are not font = self.localeInfo[self.canonLangNick(nick)][2] - if font == "bterm" or font == "none": + if font == "none": return "latarcyrheb-sun16" else: return font diff --git a/loader2/Makefile b/loader2/Makefile index 9e28934e4..0492e7eac 100644 --- a/loader2/Makefile +++ b/loader2/Makefile @@ -9,8 +9,6 @@ endif SLANGLIB = -lslang NEWTLIB = -lnewt -BTERMLIB = -lbterm -lbogl -WLITELIB = -lwlite ISYSLIB = ../isys/libisys.a GUNZIP = -lz DMLIB = -ldevmapper -lselinux -lsepol @@ -44,8 +42,6 @@ ifeq (1, $(USEDIET)) CFLAGS += -DGZLIB=1 -DDIET=1 DIET=diet CC=$(DIET) $(REALCC) -BTERMLIB = -lbtermdiet -lbogldiet -WLITELIB = -lwlitediet ISYSLIB = ../isys/libisys-diet.a GUNZIP = ../isys/gzlib/libgunzip-diet.a @@ -70,14 +66,7 @@ LANGS = $(shell cut -f 2 ../lang-table | egrep -v '(^en$$)') TR = $(patsubst %,tr/%.tr,$(LANGS)) TRFILES = $(patsubst %,%.tr,$(LANGS)) -all: $(BINS) loader.tr font.bgf.gz - -font.bgf.gz: /usr/lib/bogl/font.bdf.gz /usr/bin/reduce-font unicode-linedraw-chars.txt - zcat /usr/lib/bogl/font.bdf.gz > font.bdf - export LANG=en_US.UTF-8; (cat unicode-linedraw-chars.txt; for I in ../po/*.po ../po/timeconfig/*.po ; do msgconv -t utf-8 $$I; done) | reduce-font font.bdf > font-reduced.bdf - bdftobogl -b font-reduced.bdf > font.bgf - rm -f font.bdf font-reduced.bdf - gzip -9 -f font.bgf +all: $(BINS) loader.tr loader.tr: $(TR) ../lang-table (cd tr; ls $(TRFILES) | cpio --quiet -Hcrc -o |gzip -9) > $@ @@ -126,7 +115,7 @@ loader-net.o: loader.c loader: loader.o $(OBJS) $(NETOBJS) $(CC) -g $(STATIC) -o $@ $^ -lpopt \ $(HWLIBS) $(ISYSLIB) $(GUNZIP) $(UNICODELIB) \ - -lpump -lresolv $(NEWTLIB) $(SLANGLIB) $(BTERMLIB) $(WLITELIB) $(DMLIB) + -lpump -lresolv $(NEWTLIB) $(SLANGLIB) $(DMLIB) clean: rm -f *.o *~ .depend init ctype.c mkctype \ @@ -151,7 +140,6 @@ install: all install -m 644 unicode-linedraw-chars.txt $(DESTDIR)/$(RUNTIMEDIR)/loader install -m 644 loader.tr $(DESTDIR)/$(RUNTIMEDIR)/loader install -m 644 module-info $(DESTDIR)/$(RUNTIMEDIR)/loader - install -m 644 font.bgf.gz $(DESTDIR)/$(RUNTIMEDIR)/loader dirbrowser: dirbrowser.c gcc -DSTANDALONE -D_FORTIFY_SOURCE=2 -Wall -Werror -ggdb -o dirbrowser dirbrowser.c -lnewt -lslang diff --git a/loader2/lang.c b/loader2/lang.c index b8223a14d..2e6fdb1bc 100644 --- a/loader2/lang.c +++ b/loader2/lang.c @@ -38,8 +38,6 @@ #include "../isys/lang.h" #include "../isys/isys.h" -static int startBterm(int flags); - struct aString { unsigned int hash; short length; @@ -229,9 +227,8 @@ static int setupLanguage(int choice, int flags) { logMessage(DEBUGLVL, "going to set language to %s", languages[choice].lc_all); /* load the language only if it is displayable. if they're using * a serial console or iSeries vioconsole, we hope it's smart enough */ - if ((!strcmp(languages[choice].font, "bterm") && !FL_SERIAL(flags) && - !FL_VIRTPCONSOLE(flags) && !isVioConsole() && startBterm(flags)) || - !strcmp(languages[choice].font, "none")) { + if ((!strcmp(languages[choice].font, "none") && !FL_SERIAL(flags) && + !FL_VIRTPCONSOLE(flags) && !isVioConsole())) { if (FL_KICKSTART(flags)) return 0; newtWinMessage("Language Unavailable", "OK", @@ -330,19 +327,6 @@ int setLanguage (char * key, int flags) { return -1; } -static int startBterm(int flags) { - int rc; - - stopNewt(); - rc = isysStartBterm(); - - /* HACK: sleep to give the console time to adjust */ - sleep(1); - - startNewt(flags); - return rc; -} - int chooseLanguage(char ** lang, int flags) { int choice = 0; char ** langs; diff --git a/stubs/Makefile b/stubs/Makefile index 65307d001..138c7183a 100644 --- a/stubs/Makefile +++ b/stubs/Makefile @@ -9,7 +9,7 @@ TARGETS= $(LIBUTF8) all: $(TARGETS) libunicode-lite.a $(LIBUTF8): unicode-lite.c - gcc -fPIC -shared -o $@ $< -lwlite -D_FORTIFY_SOURCE=2 + gcc -fPIC -shared -o $@ $< -D_FORTIFY_SOURCE=2 libunicode-lite.a: libunicode-lite.a($(OBJECTS)) diff --git a/stubs/unicode-lite.c b/stubs/unicode-lite.c index f0725e7f3..87c2b6594 100644 --- a/stubs/unicode-lite.c +++ b/stubs/unicode-lite.c @@ -15,27 +15,8 @@ * Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. */ - -#define WLITE_REDEF_STDC 0 -#include <wlite_wchar.h> -#include <wlite_wctype.h> -#include <pthread.h> - -int wcwidth (wchar_t c) { - return wlite_wcwidth(c); -} - -size_t mbrtowc (wchar_t *pwc, const char *s, size_t n, void *ps) { - return wlite_mbrtowc (pwc, s, n, ps); -} - -int iswspace (wchar_t c) { - return wlite_iswctype((c), wlite_space_); -} - -size_t wcrtomb(char *s, wchar_t wc, void *ps) { - return wlite_wcrtomb (s, wc, ps); -} +#include <stdlib.h> +#include <locale.h> const char * __dgettext(const char * domainname, const char * msgid) { return msgid; @@ -450,26 +450,6 @@ class InstallInterface: return True def run(self, id, dispatch): - # set up for CJK text mode if needed - oldlang = None - if (flags.setupFilesystems and - (id.instLanguage.getFontFile(id.instLanguage.getCurrent()) == "bterm") - and self.isRealConsole()): - log.info("starting bterm") - rc = 1 - try: - rc = isys.startBterm() - time.sleep(1) - except Exception, e: - log.critical("got an exception starting bterm: %s" %(e,)) - - if rc == 1: - log.warning("unable to start bterm, falling back to english") - oldlang = id.instLanguage.getCurrent() - log.warning("old language was %s" %(oldlang,)) - id.instLanguage.setRuntimeLanguage("en_US.UTF-8") - id.instLanguage.setRuntimeDefaults(oldlang) - if id.instLanguage.getFontFile(id.instLanguage.getCurrent()) == "none": log.info("run: setting default runtime language") oldlang = id.instLanguage.getCurrent() diff --git a/textw/language_text.py b/textw/language_text.py index ab2a8ab7c..8e481e940 100644 --- a/textw/language_text.py +++ b/textw/language_text.py @@ -55,31 +55,15 @@ class LanguageWindow: return INSTALL_OK if (flags.setupFilesystems and - instLanguage.getFontFile(choice) == "bterm" + instLanguage.getFontFile(choice) == "none" and textInterface.isRealConsole()): - # bterm to the rescue... have to shut down the screen and - # create a new one, though (and do a sleep) - log.info("starting bterm") - try: - screen.finish() - rc = isys.startBterm() - time.sleep(1) - except Exception, e: - log.error("got an exception starting bterm: %s" %(e,)) - rc = 1 - newscreen = SnackScreen() - textInterface.setScreen(newscreen) - screen = newscreen - - if rc == 1: - ButtonChoiceWindow(screen, "Language Unavailable", - "%s display is unavailable in text mode. " - "The installation will continue in " - "English." % (choice,), - buttons=[TEXT_OK_BUTTON]) - instLanguage.setRuntimeDefaults(choice) - return INSTALL_OK - + ButtonChoiceWindow(screen, "Language Unavailable", + "%s display is unavailable in text mode. " + "The installation will continue in " + "English." % (choice,), + buttons=[TEXT_OK_BUTTON]) + instLanguage.setRuntimeDefaults(choice) + return INSTALL_OK instLanguage.setRuntimeLanguage(choice) instLanguage.setDefault(choice) |