emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [feature/native-comp] breakage on build


From: Phillip Lord
Subject: Re: [feature/native-comp] breakage on build
Date: Fri, 05 Feb 2021 21:50:24 +0000
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux)

Eli Zaretskii <eliz@gnu.org> writes:

>> From: Phillip Lord <phillip.lord@russet.org.uk>
>> Cc: akrl@sdf.org,  emacs-devel@gnu.org
>> Date: Fri, 05 Feb 2021 20:37:31 +0000
>> 
>> I have checked the library paths as well as I know how (gcc
>> --print-search-dirs). I have reformatted the output with some new lines
>> to make it readable.
>
> I'm not sure I understand: do these directories really exist, and do
> they hold the libraries gcc is looking for?  I mean these directories:

No. The lib/gcc didn't exist at first. If they did hold the libraries
GCC was looking for, I presume it would work. I have no idea where all
that strangeness with relative paths which look to me like they resolve
to the same places repeatedly comes from.


>
>> ** Search paths (broken)
>>    gcc --print-search-dirs
>>    install:

>
> If they do exist, does it mean you duplicated the entire MinGW GCC
> installation under the same directory that is the parent of the
> Emacs's bin/ directory?

I have tried copying /msys64/mingw64/lib/gcc into the Emacs installation
at /lib, yes. That adds 140 Mb to the install, but achieves nothing at
the moment.


>
> What does the following command produce?
>
>   gcc -print-file-name=crtbegin.o


gcc -print-file-name=crtbegin.o
c:/Users/Administrator/Desktop/emacs-28.0.50-snapshot-feature_native-comp-windows-2021-02-04/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/crtbegin.o

This file does exist.


>
>> The equivalent version for an Emacs run from mingw64 shell (which works
>> and JIT compiles), I get this.
>> 
>> 
>> 
>> ** Search paths (working)
>> 
>>    gcc --print-search-dirs
>> install: C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/
>> programs:
>> =C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/;C:/msys64/mingw64/bin/../lib/gcc/;C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw324/10.2.0/../../../../x86_64-w64-mingw32/bin/x86_64-w64-mingw32/10.2.0/;C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/bin/
>> 
>>    libraries:
>>    =C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/;
>>    C:/msys64/mingw64/bin/../lib/gcc/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/lib/x86_64-w64-mingw32/10.2.0/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/lib/../lib/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../x86_64-w64-mingw32/10.2.0/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../lib/;
>>    
>> D:/a/_temp/msys/msys64/mingw64/x86_64-w64-mingw32/lib/x86_64-w64-mingw32/10.2.0/;D:/a/_temp/msys/msys64/mingw64/x86_64-w64-mingw32/lib/../lib/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../../x86_64-w64-mingw32/lib/;
>>    
>> C:/msys64/mingw64/bin/../lib/gcc/x86_64-w64-mingw32/10.2.0/../../../;D:/a/_temp/msys/msys64/mingw64/x86_64-w64-mingw32/lib/
>
> Does the mingw64 shell set some GCC-related environment variables,
> like COMPILER_PATH or LIBRARY_PATH?


No.


> Alternatively, could it be that under the mingw64 shell Emacs invokes
> a different copy of gcc/libgccjit, the one that is in its "normal"
> installation tree and not in the Emacs tree?


Yes. I do not know how much or how little of the mingw64 install that
Emacs is using; it could be a missing DLL, config file anything at
all. But, the -no-deps version of Emacs happily does native-comp when
launched from inside a mingw64 shell.

I believe that the errors we are getting from Emacs launched from file
explorer indicate that it is finding the packaged libgccjit; I presumed
that it is this that is called as.exe and ld.exe. But Andrea can
probably answer that authoratitive.

Phil



reply via email to

[Prev in Thread] Current Thread [Next in Thread]