J閞鬽e Marant <[EMAIL PROTECTED]> writes: > "Davide G. M. Salvetti" <[EMAIL PROTECTED]> writes: > >> BTW, I think the issue of /usr/local/ in load-path is a major one to >> allow emacsen add-on packages to install correctly. However, for the >> moment I fail to understand why that path gets added correctly on >> emacs21 while it fails to do so on emacs-snapshot; I resorted to the >> 01-emacs-snapshot-fixes.el hack myself. > > Is it an emacs-snapshot issue or an emacsen-common one?
I think it's an emacs-snapshot issue. There's no code in emacsen-common that adds these entries, $ dpkg -L emacsen-common | xargs grep --files-with-match /usr/local /usr/share/emacs/site-lisp/debian-startup.el $ grep /usr/local /usr/share/emacs/site-lisp/debian-startup.el directories, but after the /usr/local/ directories. After modifying ;; Find the last /usr/local/ element. (string-match "^/usr/local" (car lp-rest))) (error "No /usr/local/ prefixed paths in load-path")) $ dpkg -L emacsen-common | xargs grep --files-with-match /etc/emacs /usr/share/emacs/site-lisp/debian-startup.el /usr/lib/emacsen-common/packages/install/emacsen-common $ grep /etc/emacs /usr/share/emacs/site-lisp/debian-startup.el (let ((common-dir "/etc/emacs/site-start.d") $ grep /etc/emacs /usr/lib/emacsen-common/packages/install/emacsen-common cp /etc/emacs/site-start.d/00debian-vars.el /etc/${FLAVOR}/site-start.d but note that `debian-startup.el' expects them to be there. I went grepping for `/usr/local' in the rules files of both emacs21 and emacs-snapshot. I don't have time to do any extensive investigation right now, but I found this in the emacs21 rules file: local_lpath := /etc/emacs${major_ver}:/etc/emacs local_lpath := ${local_lpath}:/usr/local/share/emacs/${runtime_ver}/site-lisp local_lpath := ${local_lpath}:/usr/local/share/emacs/site-lisp local_lpath := ${local_lpath}:/usr/share/emacs/${runtime_ver}/site-lisp local_lpath := ${local_lpath}:/usr/share/emacs/site-lisp The corresponding lines in the emacs-snapshot rules file look like this: local_lpath := $(EMACS_COMMON)/etc/${bin_name}:$(EMACS_COMMON)/etc/emacs local_lpath := ${local_lpath}:$(EMACS_COMMON)/usr/local/share/emacs/${runtime_ver}/site-lisp local_lpath := ${local_lpath}:$(EMACS_COMMON)/usr/local/share/emacs/site-lisp local_lpath := ${local_lpath}:$(EMACS_COMMON)/usr/share/emacs/${runtime_ver}/site-lisp local_lpath := ${local_lpath}:$(EMACS_COMMON)/usr/share/emacs/site-lisp Nothing suspicious there. However, the variable `local_lpath' is used in two places in the emacs21 file, but only in one place in the emacs-snapshot file. Here's the snippet of the emacs21 file where it is used: define build_cmd ${MAKE} CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \ prefix=/usr \ sharedstatedir=/var/lib \ libexecdir=/usr/lib \ infodir=/usr/share/info \ manext=.1emacs${major_ver} \ locallisppath=${local_lpath} endef emacs_inst = (cd debian/${1} && \ PATH=${pwd}/debian/bin/info:${PATH} ${MAKE} install \ INSTALL_STRIP="-s" \ debepkgdir=${pwd}/debian/${2} \ prefix=${pwd}/debian/${2}/usr \ sharedstatedir=${pwd}/debian/${2}/var/lib \ libexecdir=${pwd}/debian/${2}/usr/lib \ infodir=${pwd}/debian/${2}/usr/share/info/emacs-${major_ver} \ mandir=${pwd}/debian/${2}/usr/share/man \ manext=.1emacs${major_ver} \ locallisppath=${local_lpath}) The corresponding snippet of the emacs-snapshot file looks like this: define build_cmd ${MAKE} CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" endef emacs_inst = (${MAKE} install \ INSTALL_STRIP="-s" \ prefix=${1}/usr \ sharedstatedir=${1}/var/lib \ localstatedir=${1}/var \ libexecdir=${1}/usr/lib \ infodir=${1}/usr/share/info/${info_emacsdir} \ mandir=${1}/usr/share/man \ manext=.1${bin_name} \ locallisppath=${local_lpath}) Note how the `locallisppath=${local_lpath}' argument to `${MAKE}' appears in the emacs21 version of `debian/rules', but not in the emacs-snapshot version. I don't know yet if this is the root of the problem; I'm attempting to build with this patch installed, --- old/debian/rules +++ new/debian/rules @@ -339,7 +339,8 @@ ${expand_file_subst_vars} define build_cmd - ${MAKE} CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" + ${MAKE} CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" \ + locallisppath=${local_lpath} endef emacs_inst = (${MAKE} install \ but it seems me and dpatch don't get along very well. Last time I built I ended up with four declarations of `debian-emacs-flavor', and this time I really can't seem to make it happy --- or to work at all. Every time I change something in `debian/' or update from your archive dpatch gets extremely confused and the only way out seems to be a fresh Emacs checkout followed by a fresh emacs-snapshot checkout. That's what I'm doing now. I'll let you know what happens. -- Daniel Brockman <[EMAIL PROTECTED]> -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]