Path: utzoo!attcan!uunet!decwrl!ucbvax!osf.org!meissner From: meissner@osf.org Newsgroups: comp.emacs Subject: load-path Message-ID: <9007051730.AA01785@curley.osf.org> Date: 5 Jul 90 17:30:52 GMT Sender: daemon@ucbvax.BERKELEY.EDU Lines: 44 | I have been recently compiling up GNU emacs 18.55 and have run into a bit of a | problem with the load-path variable. The default load-path on our system is | "/usr/local/emacs/lisp". I would like to ADD to the list "/usr/local/lisp". | | I tried setting it in "site-init.el" when compiling. I used: | | (setq load-path (append (list "/usr/local/lisp") load-path)) | | This had NO EFFECT. When I fired up the new emacs and checked to see what my | load-path was is only showed "/usr/local/emacs/lisp". Putting the 'setq' | statement into the default.el helps, but if someone needs that path for things | in their ~/.emacs file, it causes an init file error (and rightfully so). I believe this is due to the way emacs dumps itself. | Is there an easy way to insure that everyone has a particular load-path when | starting up. If they change it in their ".emacs", then that's their problem, | but I would like to guarantee that they have the 2 mentioned paths in their | load-path on startup. What I've done in the past is modify the PATH_LOADSEARCH define in src/paths.h to have all of the directories you wish to seach, separated by colons, ie: #define PATH_LOADSEARCH "/usr/local/emacs/lisp:/usr/local/lisp" This works because src/lread.c has the following code: init_read () { char *normal = PATH_LOADSEARCH; Lisp_Object normal_path; /* Warn if dirs in the *standard* path don't exist. */ normal_path = decode_env_path ("", normal); decode_env_path breaks a PATH-type environment variable into a CONS list.... -- Michael Meissner email: meissner@osf.org phone: 617-621-8861 Open Software Foundation, 11 Cambridge Center, Cambridge, MA Do apple growers tell their kids money doesn't grow on bushes?