16 June 2019


System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz

GNU bug report logs - #35739
[w32] Bad signature from GNU ELPA for archive-contents

Marked as fixed in versions 26.3.

Change installed in emacs-26.2.20 pretest.

diff --git a/lisp/emacs-lisp/package.el b/lisp/emacs-lisp/package.el
index 1a185de4a5..46f7c91272 100644
--- a/lisp/emacs-lisp/package.el
+++ b/lisp/emacs-lisp/package.el
@@ -1241,6 +1241,17 @@ package--check-signature-content
         (signal 'bad-signature (list sig-file)))

+(defun package--buffer-string ()
+  (let ((string (buffer-string)))
+    (when (and buffer-file-coding-system
+               (> (length string) 0))
+      (put-text-property 0 1 'package--cs buffer-file-coding-system string))
+    string))
+(defun package--cs (string)
+  (and (> (length string) 0)
+       (get-text-property 0 'package--cs string)))
 (defun package--check-signature (location file &optional string async callback unwind)
   "Check signature of the current buffer.
 Download the signature file from LOCATION by appending \".sig\"
@@ -1260,8 +1271,12 @@ package--check-signature

 UNWIND, if provided, is a function to be called after everything
 else, even if an error is signaled."
-  (let ((sig-file (concat file ".sig"))
-        (string (or string (buffer-string))))
+  (let* ((sig-file (concat file ".sig"))
+         (string (or string (package--buffer-string)))
+         (cs (package--cs string)))
+    ;; Re-encode the downloaded file with the coding-system with which
+    ;; it was decoded, so we (hopefully) get the exact same bytes back.
+    (when cs (setq string (encode-coding-string string cs)))
     (package--with-response-buffer location :file sig-file
       :async async :noerror t
       ;; Connection error is assumed to mean "no sig-file".
@@ -1529,7 +1544,7 @@ package--download-one-archive
     :error-form (package--update-downloads-in-progress archive)
     (let* ((location (cdr archive))
            (name (car archive))
-           (content (buffer-string))
+           (content (package--buffer-string))
            (dir (expand-file-name (format "archives/%s" name) package-user-dir))
            (local-file (expand-file-name file dir)))
       (when (listp (read content))
@@ -1538,7 +1553,8 @@ package--download-one-archive
                 (member name package-unsigned-archives))
             ;; If we don't care about the signature, save the file and
             ;; we're done.
-            (progn (let ((coding-system-for-write 'utf-8))
+            (progn (let ((coding-system-for-write
+                          (or (package--cs content) 'utf-8)))
                      (write-region content nil local-file nil 'silent))
                    (package--update-downloads-in-progress archive))
           ;; If we care, check it (perhaps async) and *then* write the file.
@@ -1546,7 +1562,7 @@ package--download-one-archive
            location file content async
            ;; This function will be called after signature checking.
            (lambda (&optional good-sigs)
-             (let ((coding-system-for-write 'utf-8))
+             (let ((coding-system-for-write (or (package--cs content) 'utf-8)))
                (write-region content nil local-file nil 'silent))
              ;; Write out good signatures into archive-contents.signed file.
              (when good-sigs
@@ -1838,15 +1854,17 @@ package-install-from-archive
           (let ((save-silently t))
             (package-unpack pkg-desc))
         ;; If we care, check it and *then* write the file.
-        (let ((content (buffer-string)))
+        (let ((content (package--buffer-string)))
            location file content nil
            ;; This function will be called after signature checking.
            (lambda (&optional good-sigs)
              ;; Signature checked, unpack now.
-             (with-temp-buffer (insert content)
-                               (let ((save-silently t))
-                                 (package-unpack pkg-desc)))
+             (with-temp-buffer
+               (insert content)
+               (setq buffer-file-coding-system (package--cs content))
+               (let ((save-silently t))
+                 (package-unpack pkg-desc)))
              ;; Here the package has been installed successfully, mark it as
              ;; signed if appropriate.
              (when good-sigs

[   ]

15 June 2019


System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz

bash-4.3$ date
Sat Jun 15 22:17:37 CEST 2019
bash-4.3$ firefox -v
Mozilla Firefox 60.6.1
bash-4.3$ rm -r .mozilla
bash-4.3$ firefox https://github.com/ &
[1] 2300
bash-4.3$ alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000
alloc factor 0.900000 0.900000

bash-4.3$ ls .mozilla/firefox
6buu9lcq.default  profiles.ini
bash-4.3$ cp .mozilla/firefox/6buu9lcq.default/cookies.sqlite /tmp
bash-4.3$ sqlite3 /tmp/cookies.sqlite
SQLite version 3.13.0 2016-05-18 10:57:30
Enter ".help" for usage hints.
sqlite> .header on
sqlite> .mode csv
sqlite> .output cookies.csv
sqlite> SELECT * FROM moz_cookies;
sqlite> .quit
bash-4.3$ file cookies.csv
cookies.csv: ASCII text, with CRLF line terminators
bash-4.3$ kill 2300
bash-4.3$ rm /tmp/cookies.sqlite
bash-4.3$ cat cookies.csv
bash-4.3$ rm cookies.csv
bash-4.3$ exit

08 June 2019

Akonadi, Baloo

System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz

If you don't want Akonadi and Baloo running on startup the following files can be modified.

bash-4.3$ sed -i 's#StartServer=true#StartServer=false#' ~/.config/akonadi/akonadiserverrc
bash-4.3$ sed -i 's#Indexing-Enabled=true#Indexing-Enabled=false#' ~/.kde/share/config/baloofilerc
bash-4.3$ exit

Baloo replaced the deprecated Strigi.

[   ]

31 May 2019


System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz
Deps: guile-1.8.8.tar.gz, libpaper_1.1.26.tar.gz,

Installation of VRR version 0.9.4.

The 0.9.4 beta release was written prior to Guile's GH interface being deprecated.



Install the Guile 1.8 (legacy version) and libpaper. 

bash-4.3# installpkg guile1.8-1.8.8-i586-3_SBo.tgz \
> libpaper-1.1.26-i586-1_SBo.tgz


bash-4.3# exit

The GitHub repository has code upgraded for glibc 2.20 and the relocation of public
headers, it contains a modified Makefile, and the /font/convert.c file has the ctype.h
header added.

In the extracted vrr-master.zip make the following files executable.


The deprecated SCM_MAKINUM function appears in gl_misc.c, glt_kernel.c and in snarf.

Attempting to build the documentation failed.


If VRR was configured with the default '--prefix=' you can locate the documentation here.

bash-4.3# cd vrr-0.9.2-doc
bash-4.3# cp manual.html /usr/local/share/vrr/doc/manual
bash-4.3# chmod 0644 /usr/local/share/vrr/doc/manual/manual.html
bash-4.3# cp img/*.png /usr/local/share/vrr/doc/manual/img
bash-4.3# cp math/*.png /usr/local/share/vrr/doc/manual/math
bash-4.3# exit

An error message pertaining a Font metric (from import/dvi.c) accompanies
a segmentation fault and crash when opening the following files.


A segmentation fault and crash of the program also occurs when opening santiago.vrr.

NB: The rulers don't render correctly when configured with '--enable-cairo'.

[   ]


System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz

I'm not going to pursue a 32-bit build.

Lua Filters

27 May 2019

bootstrapping jdk

System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz

I noticed that last month the Oracle Java license has been changed.

I presume to use Oracle JDK as a "boot JDK" for OpenJDK would not be covered under the "Development Use" definition.

[  ]

17 May 2019


System: Slackware Linux (version 14.2)
CPUs: Intel(R) Atom(TM) CPU N270 @1.60GHz
Deps: tre-0.8.0.tar.bz2

See the previous Post on python3.

H. Väisänen's fork added bindings for Python 3 in March of 2017.

I forked tre and overwrote the python directory files with the Python 3 bindings, replacing
the deprecated PyUnicode_GetSize declaration with PyUnicode_GetLength, and adding
the AC_CONFIG_MACRO_DIRS macro to configure.ac.

bash-4.3$ cat example.py
import tre

fz = tre.Fuzzyness(maxerr = 3)
print (fz)

pt = tre.compile("Don(ald( Ervin)?)? Knuth", tre.EXTENDED)
data = """
In addition to fundamental contributions in several branches of
theoretical computer science, Donnald Erwin Kuth is the creator of the
TeX computer typesetting system, the related METAFONT font definition
language and rendering system, and the Computer Modern family of


m = pt.search(data, fz)

if m:
    print (m.groups())
    print (m[0])
bash-4.3$ python3 example.py
((95, 113), (99, 108), (102, 108))
Donnald Erwin Kuth
bash-4.3$ exit

A modified TRE is shipped with the R source code.

[   ] [   ]

At this point of time it is unclear to me what motivated the author to use REG_OK in the code and different gettext_noop messages (from those as found in grep-2.25); the writing of additional .po files might have been faciliated were the gettext_noop messages (for the most part) similar to those from the cited grep version.

bash-4.3#  ed /tmp/tre-0.8.0/lib/regerror.c
#define _(String) dgettext(PACKAGE, String)
#define gettext_noop(String) String

/* Error message strings for error codes listed in `tre.h'.  This list
   needs to be in sync with the codes listed there, naturally. */
static const char *tre_error_messages[] =
  { gettext_noop("No error"),    /* REG_OK */
    gettext_noop("No match"),    /* REG_NOMATCH */
    gettext_noop("Invalid regexp"),    /* REG_BADPAT */
    gettext_noop("Unknown collating element"),    /* REG_ECOLLATE */
    gettext_noop("Unknown character class name"),  /* REG_ECTYPE */
    gettext_noop("Trailing backslash"),    /* REG_EESCAPE */
    gettext_noop("Invalid back reference"),    /* REG_ESUBREG */
    gettext_noop("Missing ']'"),    /* REG_EBRACK */
    gettext_noop("Missing ')'"),    /* REG_EPAREN */
    gettext_noop("Missing '}'"),    /* REG_EBRACE */
    gettext_noop("Invalid contents of {}"),    /* REG_BADBR */
    gettext_noop("Invalid character range"),    /* REG_ERANGE */
    gettext_noop("Out of memory"),    /* REG_ESPACE */
    gettext_noop("Invalid use of repetition operators")    /* REG_BADRPT */

tre_regerror(int errcode, const regex_t *preg, char *errbuf, size_t errbuf_size)
    err = gettext("Unknown error");
bash-4.3$ ed /tmp/grep-2.25/lib/regcomp.c
static const char __re_error_msgid[] =
    gettext_noop ("Success") /* REG_NOERROR */
#define REG_NOMATCH_IDX (REG_NOERROR_IDX + sizeof "Success")
    gettext_noop ("No match") /* REG_NOMATCH */
#define REG_BADPAT_IDX (REG_NOMATCH_IDX + sizeof "No match")
    gettext_noop ("Invalid regular expression") /* REG_BADPAT */
#define REG_ECOLLATE_IDX (REG_BADPAT_IDX + sizeof "Invalid regular expression")
    gettext_noop ("Invalid collation character") /* REG_ECOLLATE */
#define REG_ECTYPE_IDX (REG_ECOLLATE_IDX + sizeof "Invalid collation character")
    gettext_noop ("Invalid character class name") /* REG_ECTYPE */
#define REG_EESCAPE_IDX (REG_ECTYPE_IDX + sizeof "Invalid character class name")
    gettext_noop ("Trailing backslash") /* REG_EESCAPE */
#define REG_ESUBREG_IDX (REG_EESCAPE_IDX + sizeof "Trailing backslash")
    gettext_noop ("Invalid back reference") /* REG_ESUBREG */
#define REG_EBRACK_IDX (REG_ESUBREG_IDX + sizeof "Invalid back reference")
    gettext_noop ("Unmatched [, [^, [:, [., or [=") /* REG_EBRACK */
#define REG_EPAREN_IDX (REG_EBRACK_IDX + sizeof "Unmatched [, [^, [:, [., or [=")
    gettext_noop ("Unmatched ( or \\(") /* REG_EPAREN */
#define REG_EBRACE_IDX (REG_EPAREN_IDX + sizeof "Unmatched ( or \\(")
    gettext_noop ("Unmatched \\{") /* REG_EBRACE */
#define REG_BADBR_IDX (REG_EBRACE_IDX + sizeof "Unmatched \\{")
    gettext_noop ("Invalid content of \\{\\}") /* REG_BADBR */
#define REG_ERANGE_IDX (REG_BADBR_IDX + sizeof "Invalid content of \\{\\}")
    gettext_noop ("Invalid range end") /* REG_ERANGE */
#define REG_ESPACE_IDX (REG_ERANGE_IDX + sizeof "Invalid range end")
    gettext_noop ("Memory exhausted") /* REG_ESPACE */
#define REG_BADRPT_IDX (REG_ESPACE_IDX + sizeof "Memory exhausted")
    gettext_noop ("Invalid preceding regular expression") /* REG_BADRPT */
#define REG_EEND_IDX (REG_BADRPT_IDX + sizeof "Invalid preceding regular expression")
    gettext_noop ("Premature end of regular expression") /* REG_EEND */
#define REG_ESIZE_IDX (REG_EEND_IDX + sizeof "Premature end of regular expression")
    gettext_noop ("Regular expression too big") /* REG_ESIZE */
#define REG_ERPAREN_IDX (REG_ESIZE_IDX + sizeof "Regular expression too big")
    gettext_noop ("Unmatched ) or \\)") /* REG_ERPAREN */
bash-4.3$ cd /tmp
bash-4.3$ pushd tre-0.8.0/po; ls *.po; popd
/tmp/tre-0.8.0/po /tmp
fi.po  sv.po
bash-4.3$ cd grep-2.25/po; ls *.po
af.po  cs.po  eo.po  fi.po  he.po  it.po  lt.po  pl.po  ru.po  sv.po  vi.po
be.po  da.po  es.po  fr.po  hr.po  ja.po  nb.po  pt.po sk.po  th.po  zh_CN.po
bg.po  de.po  et.po  ga.po  hu.po  ko.po  nl.po  pt_BR.po  sl.po  tr.po  zh_TW.po
ca.po  el.po  eu.po  gl.po  id.po  ky.po  pa.po  ro.po  sr.po  uk.po
bash-4.3$ exit