From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dani Moncayo Newsgroups: gmane.emacs.devel Subject: Re: Building Emacs from a new MinGW environment Date: Sat, 14 Sep 2013 16:25:03 +0200 Message-ID: References: <83sixwfdjk.fsf@gnu.org> <834n9nhhp6.fsf@gnu.org> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: ger.gmane.org 1379168709 9624 80.91.229.3 (14 Sep 2013 14:25:09 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 14 Sep 2013 14:25:09 +0000 (UTC) Cc: Emacs development discussions To: Eli Zaretskii Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Sep 14 16:25:13 2013 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1VKqmf-0002xi-4z for ged-emacs-devel@m.gmane.org; Sat, 14 Sep 2013 16:25:13 +0200 Original-Received: from localhost ([::1]:53525 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VKqme-00014w-MU for ged-emacs-devel@m.gmane.org; Sat, 14 Sep 2013 10:25:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:37567) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VKqma-00010D-JY for emacs-devel@gnu.org; Sat, 14 Sep 2013 10:25:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1VKqmZ-0008FB-P6 for emacs-devel@gnu.org; Sat, 14 Sep 2013 10:25:08 -0400 Original-Received: from mail-lb0-x22f.google.com ([2a00:1450:4010:c04::22f]:36385) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1VKqmX-0008A3-A9; Sat, 14 Sep 2013 10:25:05 -0400 Original-Received: by mail-lb0-f175.google.com with SMTP id y6so2929390lbh.6 for ; Sat, 14 Sep 2013 07:25:04 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=5l9Gq2HcjFgnzat33Dpt1/j9StrZu4KO4rjYYXTnqek=; b=w0+25viKJDyRlykbJIimu4xEkxwOt2I4D5dcM74sRKPwqXWEwdKkYCUNJzg8B1CF85 66JvUwpf4RjVoegVUnTatuJVvZ423XJvcPpDHAS4toq31Dk1Oryk/8R6FikqFazz1D+L PdSLBL47C968eKQva4CDRBF9cYVs5ZT6cFRdh7FVQUBxlwa11ZA7dFgm5mJXZa4UedRI cv7XhDdStl5qTd7WH2erBzzNZkcBncfWb02KvAQERj7DKlM+5KtNlJWKOOgGVG2Kjbd5 O04a+rYaDrYxXSVNd2wV3dyuWvAKTK+oQPkPBp7Yn74QOoAAunXEdtaS7J/te1ZAD4iP zOig== X-Received: by 10.112.149.197 with SMTP id uc5mr16228633lbb.19.1379168704016; Sat, 14 Sep 2013 07:25:04 -0700 (PDT) Original-Received: by 10.114.176.231 with HTTP; Sat, 14 Sep 2013 07:25:03 -0700 (PDT) In-Reply-To: <834n9nhhp6.fsf@gnu.org> X-detected-operating-system: by eggs.gnu.org: Error: Malformed IPv6 address (bad octet value). X-Received-From: 2a00:1450:4010:c04::22f X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:163340 Archived-At: > The %emacs_dir% part was supposed to be expanded. If nothing else > comes up from checking the installed packages, try to run the command > > temacs --batch --load loadup bootstrap > > under GDB, and see why the expansion doesn't happen. Caveat: my knowledge of gdb and debugging emacs is almost zero :). However, after a few hours, I think I've found out something. I've looked for the first call to "Fexpand_file_name" which returns a "bad" file name (bad = containing a literal "%emacs_dir%"). It is this one: #0 Fexpand_file_name (name=57476769, default_directory=57476785) at C:/msys/home/dani/emacs/emacs.git/src/fileio.c:1437 #1 0x01119643 in Fexpand_file_name (name=57476753, default_directory=57422161) at C:/msys/home/dani/emacs/emacs.git/src/fileio.c:930 #2 0x011bf86f in init_callproc () at C:/msys/home/dani/emacs/emacs.git/src/callproc.c:1616 #3 0x010dad7c in main (argc=5, argv=0x972af8) at C:/msys/home/dani/emacs/emacs.git/src/emacs.c:1325 The parameters of the call in frame #0 were: (gdb) p SSDATA(name) $1 = 0x36c4d50 <__register_frame_info+57429328> "%emacs_dir%/share/emacs/24.3.50/etc/" (gdb) p SSDATA(default_directory) $3 = 0x36c4d7c <__register_frame_info+57429372> "c:/msys/home/dani/emacs/build/src/" The parameters of the call in frame #1 were: (gdb) p SSDATA(name) $4 = 0x36c4d48 <__register_frame_info+57429320> "GNU" (gdb) p SSDATA(default_directory) $5 = 0x36c4204 <__register_frame_info+57426436> "%emacs_dir%/share/emacs/24.3.50/etc/" IIUC, the function call at frame 0 failed to expand the default directory passed to the function call at frame 1. Now, It seems to me that the code responsible for the expansion of "%emacs_dir%" is this snippet of "Fexpand_file_name": /* If the file name has special constructs in it, call the corresponding file handler. */ handler = Ffind_file_name_handler (name, Qexpand_file_name); if (!NILP (handler)) { handled_name = call3 (handler, Qexpand_file_name, name, default_directory); if (STRINGP (handled_name)) return handled_name; error ("Invalid handler in `file-name-handler-alist'"); } But I observe that the call to "Ffind_file_name_handler" returns "Qnil", and therefore the expansion (the call to "call3") is not carried out. Debugging inside "Ffind_file_name_handler", I see that the "for" loop is never entered. Does this gives you a clue of what is failing? If you need more info, just tell me what commands should I run. -- Dani Moncayo