From mboxrd@z Thu Jan 1 00:00:00 1970 From: Nick Dokos Subject: Re: list-load-path-shadows Date: Wed, 05 Sep 2012 09:54:32 -0400 Message-ID: <6715.1346853272@alphaville> References: <8533.1346780053@alphaville.americas.hpqcorp.net> Reply-To: nicholas.dokos@hp.com Return-path: Received: from eggs.gnu.org ([208.118.235.92]:60738) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T9G4G-0008Kt-SM for emacs-orgmode@gnu.org; Wed, 05 Sep 2012 09:55:02 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1T9G49-0004cN-Ie for emacs-orgmode@gnu.org; Wed, 05 Sep 2012 09:54:56 -0400 Received: from g5t0009.atlanta.hp.com ([15.192.0.46]:2014) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1T9G49-0004bg-Dq for emacs-orgmode@gnu.org; Wed, 05 Sep 2012 09:54:49 -0400 In-Reply-To: Message from tsd@tsdye.com (Thomas S. Dye) of "Tue, 04 Sep 2012 17:16:37 -1000." List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: "Thomas S. Dye" Cc: Org-mode Thomas S. Dye wrote: > Nick Dokos writes: > > > Thomas S. Dye wrote: > > > >> Aloha all, > >> > >> I'm working to understand why my initialization files don't work if I > >> compile org from git, but do seem to work (that is, initialization runs > >> to completion) when I don't compile org from git. Right now I've > >> installed org from git and have run make uncompiled. > >> > > > > It might be a good idea to run with --debug-init in the compiled case > > and get a backtrace. > > Hi Nick, > > After make compile, starting emacs --debug-init yields this backtrace: > > Debugger entered--Lisp error: (void-function org-find-library-dir) > (org-find-library-dir "org") > (file-name-directory (org-find-library-dir "org")) > (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org"))) > (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org")))) > (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org"))))) > (file-name-as-directory (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org")))))) > (expand-file-name "ditaa.jar" (file-name-as-directory (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org"))))))) > eval((expand-file-name "ditaa.jar" (file-name-as-directory (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org")))))))) > custom-initialize-reset(org-ditaa-jar-path (expand-file-name "ditaa.jar" (file-name-as-directory (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org")))))))) > custom-declare-variable(org-ditaa-jar-path (expand-file-name "ditaa.jar" (file-name-as-directory (expand-file-name "scripts" (file-name-as-directory (expand-file-name "../contrib" (file-name-directory (org-find-library-dir "org"))))))) "Path to the ditaa jar executable." :group org-babel :type string) > > AFAICT, org-find-library-dir is a macro defined in org-compat.el. Not > sure why compiling would make it disappear. Initialization runs to > completion when org isn't compiled. > > > I doubt the shadowing you discuss below makes a difference here (but > > I could be wrong). > > Looks like I was wrong :-) The custom shadowing seems to play a role. Just guessing, it's probably a chicken-and-egg situation: you load the custom file before org gets initialized and there is no autoload that manages to get the macro defined before it is used. One way to break the loop is to not use the macro in your custom file: replace it by its definition. Another way is to delete the customization of org-ditaa-jar-path from the custom file and include it after org gets initialized. Both of these are to be considered workaround hacks than solutions, but it's hard to propose a solution without knowing exactly what the problem is. If you still can't make it work, please post the initialization file(s) and the two custom files and maybe somebody can figure out something. HTH, Nick