Problems with byte-compilation

Bug #544451 reported by Tim
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
nXhtml
In Progress
Low
Unassigned

Bug Description

nXhtml fails to byte compile itself when running "nxhtmlmaint-start-byte-compilation". For each of the ".el" files it complains:

   ** Compile <filename>
   Warning: Could not find simple.el nor simple.elc
    Cannot open load file: bytecomp

Steps to reproduce:

    1. Run "emacs-Q-nxhtml" to start a new instance.
    2. Run "nxhtmlmaint-start-byte-compilation".
    3. When the new instance starts up you will see these errors.
    4. It will finish with "success": "Byte compiling nXhtml is ready, restart Emacs to use the compiled files"

Funnily enough both "simple.el(c)" and "bytecomp.el(c)" are on the load path.

I'm using the "emacs-git" package on Arch Linux, and nxhtml 2.07 rel. 602.

BTW, 'nxhtml-report-bug' now only shows some boilerplate about bug reporting.

Revision history for this message
Tim (thermans) wrote :
Revision history for this message
Tim (thermans) wrote :

BTW, this is adjunct to Bug #538635. Same realm of error, different error message

Revision history for this message
lborgman (lennart-borgman) wrote :

Hi Tim, thanks. Those compilation bugs are frustrating. I wonder what is going on here.

Somehow I may have got load-path wrong. I have added some trace messages. Can you please try again and show me a part of the message buffer with information about "newlp" and "extra-load-path"?

Changed in nxhtml:
importance: Undecided → Medium
status: New → In Progress
Revision history for this message
Jimmy Yuen Ho Wong (wyuenho) wrote :

Emacs's GIT repo hadn't been updated in more then 3 months. Are you using the latest Emacs 23.2 bzr branch HEAD? I remember there was a few months I couldn't compile nxhtml on Emacs trunk.

Revision history for this message
Tim (thermans) wrote :

Got the same thing with bzr head. Let me try and pull Lennart's trace stuff and retest.

Revision history for this message
Tim (thermans) wrote :
Revision history for this message
lborgman (lennart-borgman) wrote :

Thanks Tim and Jimmy,

I think I understand what went wrong now (or I hope I do that). I assumed that the environment variable EMACSLOADPATH was set inside Emacs always, but it looks like that is wrong.

Tim, can you please try with the new files I just uploaded?

Revision history for this message
Tim (thermans) wrote :

Used latest emacs bzr HEAD and nxhtml branch 609. Still had the problem. Attached is the messages file after the attemp.

Revision history for this message
lborgman (lennart-borgman) wrote :

Thanks Tim.

I still do not understand what is wrong. Is there any information in the compilation buffer? Could you please show me the first entries there?

Revision history for this message
lborgman (lennart-borgman) wrote :

There might have been a problem with that the compilation buffer is read-only. (Why did not that hit me?)

I would be glad if you tried again with the latest beta I just uploaded.

Revision history for this message
Tim (thermans) wrote :

Aha, the compilation buffer is indeed read-only! (Attaching a screen shot).

Revision history for this message
Tim (thermans) wrote :

But unfortunately branch 610 still does not fix. See attached copy of compile log.

Revision history for this message
lborgman (lennart-borgman) wrote :

Hi Tim,

Yes, it should be read-only. (I forgot to override this in my previous change, but that is fixed in 610.)

Could you please try this command instead for byte compiling

   M-x nxhtmlmaint-byte-recompile

That should also byte compile nXhtml but it starts a little bit different. It uses the current Emacs.

(At this point I am starting to think that the trouble we are going through here is a bit ironic. I did arrange byte compiling this way to avoid trouble. But that was long term wise, not in the short perspective ... ;-)

Revision history for this message
Tim (thermans) wrote :

You're right, it is a bit ironic :-)

I'm afraid to say that the problem is still there on branch 612. I won't post new output as they look exactly the same as before.

Revision history for this message
lborgman (lennart-borgman) wrote :

Thanks Tim.

Thinking..................................

Could you please do

  M-: (setq x (getenv "EMACSLOADPATH"))

and then show the value of x with

  C-h v x

Revision history for this message
lborgman (lennart-borgman) wrote :

I think I might have done the same mistake as I often see and comment on. I forgot to make the path separator platform independent.

Could you please try the new beta 2.07 I have just uploaded and see if that solves the problem?

Revision history for this message
Tim (thermans) wrote :

You have cracked it my friend! It works now. Good work.

One thing I have noted is that I have never seen "EMACSLOADPATH" set natively as an environment variable. Not Windows, Not OSX, not Linux. It may just be my experience but it doesn't seem like this can be relied on to provide the default load path.

Thanks again for fixing this.

Revision history for this message
lborgman (lennart-borgman) wrote :

Thanks Tim.

I think your comment about EMACSLOADPATH is right. And I wonder if I have taken the best road here. I will think about it, but for the next release I will keep this version.

Changed in nxhtml:
status: In Progress → Fix Committed
Changed in nxhtml:
status: Fix Committed → In Progress
Changed in nxhtml:
importance: Medium → Low
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.