Closed tajmone closed 3 years ago
A few points on this matter:
I'm "obsoleting" the distribution handling, although slightly useful, I feel it is too much cruft, and as long as "el-get" installation works, users have a much easier way to install it, and although this currently limits audience to Emacs-users, in the future we should re-think this when we support a few more editors, and do it in a more modern fashion (I also see little use of the "central server" flavour, which is one reason for the distribution packaging)
I think that once you have failed an initial build there are things left laying around which prevents a second initial build, try "make cleaner" and "make"
(The c-xref.bs
is a binary built by the initial build using default sources for some things which is then used to generate target specific sources for those things, so that a target specific c-xref
can be built. This is a small part of all the magic that is built into the design of c-xrefactory
...)
I'll try MSYS2 as soon as I'm at an MSYS2-prompt.
Thanks Thoni. I tried, but still no lack.
Anyways, slightly older versions (1.6.7
vs 1.6.10
) are available as precompiled Windows binaries directly from Xref website:
file | for editor |
---|---|
xref-1.6.7-i86pcWindows.zip | Emacs, XEmacs |
xref-1.6.7-jedit-i86pcWindows.zip | jEdit |
xref-1.6.7-any.tar.gz | Emacs, XEmacs, jEdit |
If these work they should be fine as a starting point, at least to start getting a feel of the tool.
NOTE — I had to fiddle manually with the links, for they still pointed at the old mirro domain, which is mostly down (just had to change www.xref.sk to www.xrefactory.com, for they are mirrors of each other).
If this repository were to exploit Travis CI or Circle CI to actually build precompiled binary releases for Windows (via cross-compilation) it would be great!
Just some quick findings and a few comments:
the xref-1.6.7-any.tar.gz
would presumably be a source distribution, but it's interesting with the Windows-binaries, probably produced with the distribution
script and some ancient C/C++ compiler for Windows
I have no idea how they used to compile to windows in 2004, presumably many things are quite different, I would welcome any attempt to restore pure-Windows compilability, but that's not high on my priority since compiling on WSL, Cygwin, Linux and MacOS works fine.
I've succeeded in building on MSYS2, note that this is on the POSIX-variant, MSYS2 W64 and W32 maps some functions onto the Windows API, which it fails to do transparently, so you have to make provisions for compiling in this environment
In the MSYS Posix environment el-get-install
works for me
I continuously use Emacs with c-xrefactory on WSL for many of my projects, so even MSYS Posix would be low on my prio if it didn't work.
WSL is definitely something that came to my mind, I'll try and set it up and, if I manage, I'll add a script that can be used to do all the automagick setup from a fresh WSL Ubuntu install.
I think that will be no problem. c-xrefactory
actually has very few special requirements, it uses the file system and pipes, so there are not any extra libraries that you need, AFAICR.
I continuously use Emacs with c-xrefactory on WSL for many of my projects,
I've set up an Xming X11 server on the Windows side so my Emacs will open a window on the desktop. And it successfully loads c-xrefactory
via el-get
.
@thoni56, could you add to the Wiki some guidelines on how to setup c-xrefactory under Win10 using WSL/WSL2, possibly with some links/tips for Emacs too.
I've set up an Xming X11 server on the Windows side so my Emacs will open a window on the desktop.
Isn't it possible to install Emacs for Windows and interface it with c-xrefactory running under WSL?
The recommended way to install c-xrefactory
is using el-get
as is explained in the Readme. That will automatically compile it in the environment Emacs is running.
That works in Linux, Cygwin and MacOS. I haven't tried any other environment for a while. But if it has "normal" unix-like features,(make
, bash
, cc
, ...) it might work.
I don't think it is posssible to have Emacs and c-xref
communicate over a network, which is what WSL/Windows would be.
There are some remnants of a "user" concept to the "server-mode" but I don't know if and how that was working as a true server.
Anyway, if possible that would be a lot of work in an area that is mostly unknown to me.
I'll add something about setting up Emacs on WSL.
I've successfully compiled c-xrefactory
as part of the recommended installation from within Emacs using el-get
. You currently have to have zlib-devel
installed to make that build succeed (pacman -S zlib-devel
) .
I also have added some tips for setup in the readme.
NOTE: only Msys2-MSYS, which uses the Cygwin layer to emulate Linux/Unix, is supported, not Msys2-MingW* (the "Windows native" 32- and 64-bit versions).
It seems that C Xrefactory won't compile using MYS2/MinGW-64 under Windows 10 x64.
I've tried all the various approaches proposed in
INSTALL
and none worked:install-info
tool (from TextInfo).CreateXrefDistribution
fails with numerous warning and errors (see log below),make
failed too, seemingly due to a missing./c-xref.bs
file.src/
viamake
also failed, again due to missing./c-xref.bs
file.Any ideas? Is Xref supposed to be compiled as 32-bit only?
Failed Auto Create Xrefactory Distribution
Below is the output log from trying to compile c-xrefactory via
Beside various warnings during
make byacc
, the BOOTSTRAPPING phase failsFailed Make in Root Folder
Below is the output log from trying to compile c-xrefactory via
make
inside root folder.The problem seems to be a missing
./c-xref.bs
file.Failed Make in
src/
FolderBelow is the output log from trying to compile c-xrefactory via
make
insidesrc/
folder.Again, the problem seems to be a missing
./c-xref.bs
file.