unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* How to speed up emacs start time?
@ 2009-07-31  0:16 n179911
  2009-07-31  0:30 ` Drew Adams
       [not found] ` <mailman.3540.1249000245.2239.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 14+ messages in thread
From: n179911 @ 2009-07-31  0:16 UTC (permalink / raw)
  To: help-gnu-emacs

In my .emacs, I have

(setq load-path (cons "~/bin/emacslib" load-path))
(require 'icicles)

And in my ~/bin/emacslib, I have

$ ls
icicles-chg.el   icicles-doc1.el  icicles-fn.el    icicles-mode.el  icicles.el
icicles-cmd1.el  icicles-doc2.el  icicles-mac.el   icicles-opt.el
icicles-cmd2.el  icicles-face.el  icicles-mcmd.el  icicles-var.el

Can you please tell me how can I speed up emacs startup time? Is there
anyway to compile the .el. files so that emacs can come up faster?

Thank you.




^ permalink raw reply	[flat|nested] 14+ messages in thread

* RE: How to speed up emacs start time?
  2009-07-31  0:16 How to speed up emacs start time? n179911
@ 2009-07-31  0:30 ` Drew Adams
       [not found] ` <mailman.3540.1249000245.2239.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 14+ messages in thread
From: Drew Adams @ 2009-07-31  0:30 UTC (permalink / raw)
  To: 'n179911', help-gnu-emacs

> In my .emacs, I have
> (setq load-path (cons "~/bin/emacslib" load-path))
> (require 'icicles)
> 
> And in my ~/bin/emacslib, I have
> 
> $ ls
> icicles-chg.el   icicles-doc1.el  icicles-fn.el    
> icicles-mode.el  icicles.el
> icicles-cmd1.el  icicles-doc2.el  icicles-mac.el   icicles-opt.el
> icicles-cmd2.el  icicles-face.el  icicles-mcmd.el  icicles-var.el
> 
> Can you please tell me how can I speed up emacs startup time? Is there
> anyway to compile the .el. files so that emacs can come up faster?

1. C-x d ~/bin/emacslib

2. Use `m' to mark each of the icicles files, except *-chg* and *-doc*.

3. `B', then confirm, to byte compile all of the marked files.

You're done.

If you modify any of the source files that you've byte-compiled (e.g. you
downloaded a later version), you can use `M-x byte-recompile-directory' to
recompile any that whose *.elc files are out of date. That's like a mini-`make'
for byte-compiled files.






^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
       [not found] <mailman.3539.1248999408.2239.help-gnu-emacs@gnu.org>
@ 2009-07-31  0:33 ` Rafael
  2009-07-31  7:51   ` n179911
       [not found]   ` <mailman.3561.1249026712.2239.help-gnu-emacs@gnu.org>
  0 siblings, 2 replies; 14+ messages in thread
From: Rafael @ 2009-07-31  0:33 UTC (permalink / raw)
  To: help-gnu-emacs

n179911 <n179911@gmail.com> writes:

> And in my ~/bin/emacslib, I have
>
> $ ls
> icicles-chg.el   icicles-doc1.el  icicles-fn.el    icicles-mode.el  icicles.el
> icicles-cmd1.el  icicles-doc2.el  icicles-mac.el   icicles-opt.el
> icicles-cmd2.el  icicles-face.el  icicles-mcmd.el  icicles-var.el
>
> Can you please tell me how can I speed up emacs startup time? Is there
> anyway to compile the .el. files so that emacs can come up faster?

This is what I would do: In a dired buffer of the ~/bin/emacslib
directory, mark the .el files with 'M' and then byte-compile them with
'B'.


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
       [not found] ` <mailman.3540.1249000245.2239.help-gnu-emacs@gnu.org>
@ 2009-07-31  7:44   ` Elena
  2009-07-31 14:34     ` Drew Adams
  0 siblings, 1 reply; 14+ messages in thread
From: Elena @ 2009-07-31  7:44 UTC (permalink / raw)
  To: help-gnu-emacs

On 31 Lug, 00:30, "Drew Adams" <drew.ad...@oracle.com> wrote:
> If you modify any of the source files that you've byte-compiled (e.g. you
> downloaded a later version), you can use `M-x byte-recompile-directory' to
> recompile any that whose *.elc files are out of date. That's like a mini-`make'
> for byte-compiled files.

Can't you just `M-x byte-recompile-directory' on the first instance?



^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
  2009-07-31  0:33 ` Rafael
@ 2009-07-31  7:51   ` n179911
  2009-07-31  8:11     ` Jonatan Andersson
       [not found]   ` <mailman.3561.1249026712.2239.help-gnu-emacs@gnu.org>
  1 sibling, 1 reply; 14+ messages in thread
From: n179911 @ 2009-07-31  7:51 UTC (permalink / raw)
  To: Rafael; +Cc: help-gnu-emacs

Thank you. Emacs 23.1 on Mac OSX works.
But when I start emacs at terminal (instead of running Emacs.app),
emacs (in /usr/bin/emacs version 22)  complains that the .elc are
compiled for version 23.

Can you please tell me what can I do to fix this?

Thank you.

On Thu, Jul 30, 2009 at 5:33 PM, Rafael<rvf0068@gmail.com> wrote:
> n179911 <n179911@gmail.com> writes:
>
>> And in my ~/bin/emacslib, I have
>>
>> $ ls
>> icicles-chg.el   icicles-doc1.el  icicles-fn.el    icicles-mode.el  icicles.el
>> icicles-cmd1.el  icicles-doc2.el  icicles-mac.el   icicles-opt.el
>> icicles-cmd2.el  icicles-face.el  icicles-mcmd.el  icicles-var.el
>>
>> Can you please tell me how can I speed up emacs startup time? Is there
>> anyway to compile the .el. files so that emacs can come up faster?
>
> This is what I would do: In a dired buffer of the ~/bin/emacslib
> directory, mark the .el files with 'M' and then byte-compile them with
> 'B'.
>




^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
  2009-07-31  7:51   ` n179911
@ 2009-07-31  8:11     ` Jonatan Andersson
  0 siblings, 0 replies; 14+ messages in thread
From: Jonatan Andersson @ 2009-07-31  8:11 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

Having two different version of any program installed is a sure way to  
go mad.

I would suggest that you remove /usr/bin/emacs from the system (and  
emacslient et al) , and add the path to the Emacs 23.1 binary. I have  
first in my PATH variable the /Applications/Emacs.app/Contents/MacOS/:/ 
usr/bin: in my


With kindest regards
    Jonatan Andersson



On Jul 31, 2009, at 9:51 AM, n179911 wrote:

> Thank you. Emacs 23.1 on Mac OSX works.
> But when I start emacs at terminal (instead of running Emacs.app),
> emacs (in /usr/bin/emacs version 22)  complains that the .elc are
> compiled for version 23.
>
> Can you please tell me what can I do to fix this?
>
> Thank you.
>
> On Thu, Jul 30, 2009 at 5:33 PM, Rafael<rvf0068@gmail.com> wrote:
>> n179911 <n179911@gmail.com> writes:
>>
>>> And in my ~/bin/emacslib, I have
>>>
>>> $ ls
>>> icicles-chg.el   icicles-doc1.el  icicles-fn.el    icicles- 
>>> mode.el  icicles.el
>>> icicles-cmd1.el  icicles-doc2.el  icicles-mac.el   icicles-opt.el
>>> icicles-cmd2.el  icicles-face.el  icicles-mcmd.el  icicles-var.el
>>>
>>> Can you please tell me how can I speed up emacs startup time? Is  
>>> there
>>> anyway to compile the .el. files so that emacs can come up faster?
>>
>> This is what I would do: In a dired buffer of the ~/bin/emacslib
>> directory, mark the .el files with 'M' and then byte-compile them  
>> with
>> 'B'.
>>
>
>





^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
       [not found]   ` <mailman.3561.1249026712.2239.help-gnu-emacs@gnu.org>
@ 2009-07-31  8:33     ` Anselm Helbig
  2009-07-31  9:23       ` Peter Dyballa
       [not found]       ` <mailman.3567.1249032229.2239.help-gnu-emacs@gnu.org>
  2009-08-02 16:12     ` Rugxulo
  1 sibling, 2 replies; 14+ messages in thread
From: Anselm Helbig @ 2009-07-31  8:33 UTC (permalink / raw)
  To: help-gnu-emacs

Hi!

> Thank you. Emacs 23.1 on Mac OSX works.
> But when I start emacs at terminal (instead of running Emacs.app),
> emacs (in /usr/bin/emacs version 22)  complains that the .elc are
> compiled for version 23.
> 
> Can you please tell me what can I do to fix this?

The easy way is to also use emacs 23 in the terminal,
/path/to/your/emacs -nw should do it. Or just fix your PATH
environment variable so that your emacs 23 bin directory comes first.

Otherwise you'd have to use different directories for different emacs
version + one directory with the .el sources. You'd symlink your
source files over to the directories for your different emacs versions
and compile them there. This is more or less how debian's emacs
packaging works when you have multiple emacsen installed. 

In your .emacs you'd to something like this:

  (add-to-list 'load-path 
               (format "/path/to/emacs-lisp/emacs-%s" emacs-major-version))

But I'd rather use emacs 23 on the console as well. With the new
multi-tty feature you should also be able to use the same instance for
this, issue M-x server-start and then connect with `emacsclient -t'. I
heard that multi-tty doesn't yet work well on OS X, though.

HTH, 

Anselm


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
  2009-07-31  8:33     ` Anselm Helbig
@ 2009-07-31  9:23       ` Peter Dyballa
       [not found]       ` <mailman.3567.1249032229.2239.help-gnu-emacs@gnu.org>
  1 sibling, 0 replies; 14+ messages in thread
From: Peter Dyballa @ 2009-07-31  9:23 UTC (permalink / raw)
  To: Anselm Helbig; +Cc: help-gnu-emacs


Am 31.07.2009 um 10:33 schrieb Anselm Helbig:

> The easy way is to also use emacs 23 in the terminal,
> /path/to/your/emacs -nw should do it.


Which is /Applications/Emacs.app/Contents/MacOS/Emacs – and which has  
some problems with the command line options!

--
Mit friedvollen Grüßen

   Pete

One doesn't expect governments to obey the law because of some higher  
moral development.  One expects them to obey the law because they  
know that if they don't, those who aren't shot will be hanged.
				– Michael Shirley







^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
       [not found]       ` <mailman.3567.1249032229.2239.help-gnu-emacs@gnu.org>
@ 2009-07-31 10:02         ` Anselm Helbig
  2009-07-31 15:53           ` Peter Dyballa
  0 siblings, 1 reply; 14+ messages in thread
From: Anselm Helbig @ 2009-07-31 10:02 UTC (permalink / raw)
  To: help-gnu-emacs

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 535 bytes --]

At Fri, 31 Jul 2009 11:23:36 +0200,
Peter Dyballa <Peter_Dyballa@Web.DE> wrote:
> 
> 
> Am 31.07.2009 um 10:33 schrieb Anselm Helbig:
> 
> > The easy way is to also use emacs 23 in the terminal,
> > /path/to/your/emacs -nw should do it.
> 
> 
> Which is /Applications/Emacs.app/Contents/MacOS/Emacs – and which has  
> some problems with the command line options!

OK, then maybe you should rather not use Emacs at all but switch to
Textmate. 8;-)

*ducks-and-runs*


-- 
Anselm Helbig 
mailto:anselm.helbig+news2009@googlemail.com


^ permalink raw reply	[flat|nested] 14+ messages in thread

* RE: How to speed up emacs start time?
  2009-07-31  7:44   ` Elena
@ 2009-07-31 14:34     ` Drew Adams
  2009-08-01 20:09       ` Johan Bockgård
  0 siblings, 1 reply; 14+ messages in thread
From: Drew Adams @ 2009-07-31 14:34 UTC (permalink / raw)
  To: 'Elena', help-gnu-emacs

> > If you modify any of the source files that you've 
> > byte-compiled (e.g. you downloaded a later version),
> > you can use `M-x byte-recompile-directory' to
> > recompile any that whose *.elc files are out of date. 
> > That's like a mini-`make' for byte-compiled files.
> 
> Can't you just `M-x byte-recompile-directory' on the first instance?

`byte-recompile-*' only RE-compiles. It does not compile any *.el in the
directory that have not already been compiled. This means you can keep some
files uncompiled, yet still keep the *.elc up-to-date using `byte-recompile-*'.





^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
  2009-07-31 10:02         ` Anselm Helbig
@ 2009-07-31 15:53           ` Peter Dyballa
  0 siblings, 0 replies; 14+ messages in thread
From: Peter Dyballa @ 2009-07-31 15:53 UTC (permalink / raw)
  To: Anselm Helbig; +Cc: help-gnu-emacs


Am 31.07.2009 um 12:02 schrieb Anselm Helbig:

> OK, then maybe you should rather not use Emacs at all but switch to
> Textmate. 8;-)
>

Or don't give so many...

--
Mit friedvollen Grüßen

   Pete

Only two things are infinite, the universe and human stupidity, and  
I'm not sure about the former.
				– Albert Einstein







^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
  2009-07-31 14:34     ` Drew Adams
@ 2009-08-01 20:09       ` Johan Bockgård
  2009-08-01 20:26         ` Drew Adams
  0 siblings, 1 reply; 14+ messages in thread
From: Johan Bockgård @ 2009-08-01 20:09 UTC (permalink / raw)
  To: help-gnu-emacs

"Drew Adams" <drew.adams@oracle.com> writes:

>> Can't you just `M-x byte-recompile-directory' on the first instance?
>
> `byte-recompile-*' only RE-compiles. It does not compile any *.el in
> the directory that have not already been compiled.

Unless you use a prefix argument.





^ permalink raw reply	[flat|nested] 14+ messages in thread

* RE: How to speed up emacs start time?
  2009-08-01 20:09       ` Johan Bockgård
@ 2009-08-01 20:26         ` Drew Adams
  0 siblings, 0 replies; 14+ messages in thread
From: Drew Adams @ 2009-08-01 20:26 UTC (permalink / raw)
  To: 'Johan "Bockgård"', help-gnu-emacs

> >> Can't you just `M-x byte-recompile-directory' on the first 
> >> instance?
> >
> > `byte-recompile-*' only RE-compiles. It does not compile any *.el in
> > the directory that have not already been compiled.
> 
> Unless you use a prefix argument.

Right. It's good to remind about that.





^ permalink raw reply	[flat|nested] 14+ messages in thread

* Re: How to speed up emacs start time?
       [not found]   ` <mailman.3561.1249026712.2239.help-gnu-emacs@gnu.org>
  2009-07-31  8:33     ` Anselm Helbig
@ 2009-08-02 16:12     ` Rugxulo
  1 sibling, 0 replies; 14+ messages in thread
From: Rugxulo @ 2009-08-02 16:12 UTC (permalink / raw)
  To: help-gnu-emacs

Hi,

On Jul 31, 2:51 am, n179911 <n179...@gmail.com> wrote:
>
> Thank you. Emacs 23.1 on Mac OSX works.
> But when I start emacs at terminal (instead of running Emacs.app),
> emacs (in /usr/bin/emacs version 22)  complains that the .elc are
> compiled for version 23.

Surprisingly, I don't think anybody answered your question correctly
yet. So here's my lame attempt ....

Anyways, it's incompatible now due to changes in 23.1. You'll have to
compile with 22, I suppose, which will still work with 23.

(quoting from NEWS):

"During byte-compilation, Emacs 23 uses `utf-8-emacs' to write files.
As a result, byte-compiled files containing non-ASCII characters can't
be read by earlier versions of Emacs.  Files compiled by Emacs 20, 21,
or 22 are loaded correctly as `emacs-mule' (whether or not they
contain multibyte characters).  This takes somewhat more time, so it
may be worth recompiling existing .elc files which don't need to be
shared with older Emacsen."


^ permalink raw reply	[flat|nested] 14+ messages in thread

end of thread, other threads:[~2009-08-02 16:12 UTC | newest]

Thread overview: 14+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-07-31  0:16 How to speed up emacs start time? n179911
2009-07-31  0:30 ` Drew Adams
     [not found] ` <mailman.3540.1249000245.2239.help-gnu-emacs@gnu.org>
2009-07-31  7:44   ` Elena
2009-07-31 14:34     ` Drew Adams
2009-08-01 20:09       ` Johan Bockgård
2009-08-01 20:26         ` Drew Adams
     [not found] <mailman.3539.1248999408.2239.help-gnu-emacs@gnu.org>
2009-07-31  0:33 ` Rafael
2009-07-31  7:51   ` n179911
2009-07-31  8:11     ` Jonatan Andersson
     [not found]   ` <mailman.3561.1249026712.2239.help-gnu-emacs@gnu.org>
2009-07-31  8:33     ` Anselm Helbig
2009-07-31  9:23       ` Peter Dyballa
     [not found]       ` <mailman.3567.1249032229.2239.help-gnu-emacs@gnu.org>
2009-07-31 10:02         ` Anselm Helbig
2009-07-31 15:53           ` Peter Dyballa
2009-08-02 16:12     ` Rugxulo

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).