bug-auctex
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-AUCTeX] Re: rel-0-9-1; installation problem


From: David Kastrup
Subject: [Bug-AUCTeX] Re: rel-0-9-1; installation problem
Date: Thu, 07 Apr 2005 22:52:03 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

[Keeping bug-auctex copied]

Jeff Flowers <address@hidden> writes:

> David Kastrup wrote:
>> Jeff Flowers <address@hidden> writes:

>>>>>The command line was
>>>>>
>>>>>$ ./configure --prefix=d:\\emacs --with-texmf-dir=c:\\texmf
>>>>>
>>>>>(athough changing the slashes to single ones or / didn't help)
>>>>>this gave lots of stuff seeming to find tex and emacs then
>>>>
>>>>Uh oh.
>>>>
>>>>
>>>>>./mkinstalldirs /emacs/d:/emacs/site-lisp/preview
>>>>
>>>>What happens if you inside of Emacs say
>>>>M-: (expand-file-name "d:\\emacs\\site-lisp\\preview" "\\emacs") RET
>>>
>>>The result is "d:/emacs/site-lisp/preview"
>> Looks ok.
>> 
>>>>Could you post the contents of the file preview-latex.el?
>>>
>>>attached
>> [...]
>> 
>>>(add-to-list 'load-path (expand-file-name "preview" (file-name-directory 
>>>load-file-name)))
>>>(defvar preview-icondir (expand-file-name "preview/images" 
>>>(file-name-directory load-file-name)))
>> Looks ok.  Just for the record: what is the output of
>> M-: preview-icondir RET
>> 
>
> "d:/emacs/site-lisp/preview/preview/images"
>
> which I guess is wrong!!

Serves me right.  I should have also asked just where preview-latex.el
is installed.  The most likely explanation would seem that you
_manually_ copied it to the preview subdirectory, while the
installation procedure intended to place it in the site-lisp
directory.  Since the search paths are then created _relatively_ to
the preview-latex.el file, stuff breaks.

Now in ancient times (like a month ago or so), the installation
instructions demanded that you place the preview subdirectory into
your search path or let this automatically happen, then copy
preview-latex.el somewhere where it can be found.  I can't exclude the
possibility that there were oversights in updating the installation
instructions.  The file preview-latex.el you quoted definitely is a
new-style file, so it really is likely that you manually installed it
in the wrong place.

If this guess is correct, can you remember what made you do so?
Advice on some web page, previous printouts from the manual, or
something that still is left in the current instructions?  Or was this
a "lucky guess" after the normal installation broke, and you tried
fixing it?  This would really be important to reconstruct: even in
case it can be called a "user error", we want to avoid opportunities
for them as much as possible, too.

> config.log is attached. I guess from a quick browse that it may be a
> path naming problem. I may have confused the issue by trying the
> install a few times! I will clean up and have another go if you
> want, with the invocation you suggest.

I'll go through.

>   $ ./configure --prefix=d:\emacs --with-texmf-dir=c:\texmf

Fine so far.  Getting forward/backward slashes consistent in Windows
installation procedures is pretty much impossible, but the
installation procedure should get along with either.

> /bin/machine           = unknown
> /usr/bin/oslevel       = unknown
> /bin/universe          = unknown
>
> PATH: /usr/X11R6/bin
> PATH: /usr/local/bin
> PATH: /usr/bin
> PATH: /bin
> PATH: /cygdrive/c/PROGRA~1/COMMON~1/MGISHA~1/Video
> PATH: /cygdrive/c/texmf/miktex/bin/
> PATH: /cygdrive/c/WINDOWS/system32
> PATH: /cygdrive/c/WINDOWS
> PATH: /cygdrive/c/WINDOWS/System32/Wbem
> PATH: /usr/bin
> PATH: /usr/bin
> PATH: /usr/local/bin
> PATH: /cygdrive/c/Program Files/mpg123
> PATH: /cygdrive/c/Program Files/Common Files/Adaptec Shared/System
> PATH: /cygdrive/c/Program Files/emacs/bin
> PATH: /cygdrive/c/Program Files/emacs-21.2/bin

Well, there is an old Emacs in the PATH, but it should not be
reached.  One problem is the /cygdrive stuff: if any information will
be picked from the PATH variable, Emacs (which is not Cygwin) will not
be able to interpret it correctly.  But you specified enough on the
command line that this probably will not happen.

> ## ----------- ##
> ## Core tests. ##
> ## ----------- ##

[Skipping over tests that work]

> configure:1723: checking where lisp files go
> d:\emacs/bin/emacs -batch -eval (let* ((prefix(pop command-line-args-left)) 
> (expanded(pop command-line-args-left)) (x (catch 22
>        (let (reldir (dirs load-path))
>         (dolist (name (list "emacs/site-lisp" "emacs/site-packages"
>                "site-lisp" "site-packages") "NONE")
>           (dolist (dir dirs)
>             (when (and dir
>                        (setq dir (directory-file-name dir))
>                          (file-name-absolute-p dir)
>                        (file-directory-p dir)
>                        (not (string-match "\\`\\.\\."
>                            (setq reldir (file-relative-name dir expanded))))
>                          (let ((name name) (dir dir))
>                          (while (and dir name
>                                      (string= (file-name-nondirectory dir)
>                                               (file-name-nondirectory name))
>                               (setq dir (file-name-directory dir)
>                                  name (file-name-directory name))
>                             (if (and dir name)
>                                (setq dir (directory-file-name dir)
>                                     name (directory-file-name name)))))
>                           (null name))
>                  (throw 22
>                       (if (string= reldir ".") (directory-file-name prefix)
>                         (concat (file-name-as-directory prefix)
>                                 reldir))))))))))) (write-region (if (stringp 
> x) x (prin1-to-string x)) nil "./conftest-5280")) ${datadir}/emacs 
> d:\emacs/share/emacs
> Wrote c:/Documents and Settings/root/My 
> Documents/sources/preview-latex/preview-latex-0.9.1/conftest-5280
> => dummy

Further code indicates that this test failed.  It searches for a
directory in load-path that is below the d:\emacs/share/emacs
hierarchy and ends with emacs/site-lisp, emacs/site-packages,
site-lisp or site-packages.  A pity we don't see the result because of
some bug, but just "dummy".  Will be fixed.

> d:\emacs/bin/emacs -batch -eval (let* ((prefix(pop command-line-args-left)) 
> (expanded(pop command-line-args-left)) (x (catch 22
>        (let (reldir (dirs load-path))
>         (dolist (name (list "emacs/site-lisp" "emacs/site-packages"
>                "site-lisp" "site-packages") "NONE")
>           (dolist (dir dirs)
>             (when (and dir
>                        (setq dir (directory-file-name dir))
>                          (file-name-absolute-p dir)
>                        (file-directory-p dir)
>                        (not (string-match "\\`\\.\\."
>                            (setq reldir (file-relative-name dir expanded))))
>                          (let ((name name) (dir dir))
>                          (while (and dir name
>                                      (string= (file-name-nondirectory dir)
>                                               (file-name-nondirectory name))
>                               (setq dir (file-name-directory dir)
>                                  name (file-name-directory name))
>                             (if (and dir name)
>                                (setq dir (directory-file-name dir)
>                                     name (directory-file-name name)))))
>                           (null name))
>                  (throw 22
>                       (if (string= reldir ".") (directory-file-name prefix)
>                         (concat (file-name-as-directory prefix)
>                                 reldir))))))))))) (write-region (if (stringp 
> x) x (prin1-to-string x)) nil "./conftest-5280")) ${libdir}/emacs 
> NONE/lib/emacs
> Wrote c:/Documents and Settings/root/My 
> Documents/sources/preview-latex/preview-latex-0.9.1/conftest-5280
> => dummy

Ouch.  So many things go wrong here that I can't even start.  NONE is
not a good value to use for exec_path here (which I did not realize
was addressed via ${libdir}), and the relative directory test fails,
too.  Ok, so this also explains the manual installation of the startup
file and its misconfiguration.

> configure:1796: result: ${libdir}/emacs/d:/emacs/site-lisp
> configure:1810: checking
> The place for the startup file
> configure:1815: result: ${libdir}/emacs/d:/emacs/site-lisp

Whee.  I'll just quote the juciest parts.

> PDFLATEX='/cygdrive/c/texmf/miktex/bin//pdflatex'

The resulting Makefile will only work with Cygwin make, but that's
probably not a problem.

> icondir='${libdir}/emacs/d:/emacs/site-lisp/${packagelispdir}/images'

Beautiful.  It is unexpected, however, that this contains
packagelispdir in unexpanded form, when that is made absolute later
on.  I have to think about that.

> lispdir='${libdir}/emacs/d:/emacs/site-lisp'

Another prize champion.

> lispicondir='(expand-file-name "preview/images" (file-name-directory
> load-file-name))' 
> lisppackagelispdir='(expand-file-name "preview" (file-name-directory
> load-file-name))'

Astonishingly sane.

> packagelispdir='${libdir}/emacs/d:/emacs/site-lisp/preview'

Absolute, yet used in icondir...

The rest looks sane.  I'll append a patch that is supposed to deal
with everything.  You have to run patch -p0 with an input redirection
from this mail (or just the patch section) in the preview directory,
then run autoconf, and restart ./configure with the above options.
Let us see whether you fare better this time.  The packagelispdir
stuff I can't deal with sensibly right now since I am working on
replacing it with something saner, and since it worked before, there
is not much to be gained by getting the old stuff to work in
exceptional circumstances.  However, this did the right thing with
other test scenarios, so it might just work.

Attachment: txt6fkrPDmgbM.txt
Description: Text Data

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum

reply via email to

[Prev in Thread] Current Thread [Next in Thread]