[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preproces
From: |
Liu Hao |
Subject: |
Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives |
Date: |
Mon, 25 Dec 2017 22:46:00 +0800 |
User-agent: |
Mozilla/5.0 (Windows NT 6.1; WOW64; rv:52.0) Gecko/20100101 Thunderbird/52.5.0 |
On 2017/12/25 21:23, Benno Schulenberg wrote:
>
> Liu, your messages do not reach the nano-devel mailing list. Are you
> subscribed?
>
Yes. But I received no notification about bouncing. I have no idea why. :<
> Op 22-12-17 om 07:33 schreef Liu Hao:
>> On 2017/12/22 3:01, Benno Schulenberg wrote:
>>> Strange. I would have thought that the stuff in gnulib closely matches
>>> the stuff in glibc.
>>
>> Yes, it is \< and \>. At the moment I pass `--with-wordbounds` and
>> `--without-included-regex` to `configure` always, otherwise they won't
>> work on Windows.
>
> But how then have you installed the ripped-out regex part from glibc?
>
Of course. It is easy: I just install it somewhere then pass the path of
`include` and `lib` directories to `configure`. Much of this work is
done using the script here:
<https://github.com/lhmouse/nano-win/blob/master/build-nano-win.sh#L28>
> Can you show us the full output of a bare ./configure run (without any
> options) on your Windows machine? Because the idea of gnulib is to allow
> building on multiple platforms without any need for adjustments. If that
> isn't working, we need to fix it.
>
This turned out to be a duplicate of bug 50705
<https://savannah.gnu.org/bugs/?50705>. On current master it no longer
persists.
However there are other issues about gnulib:
The outputs of the following command have been attached:
(I removed GNU regex library headers and libraries from the directories
above, but CFLAGS and LDFLAGS had to be kept for ncurses.)
```sh
CPPFLAGS="-I\"$(pwd)\"/i686-w64-mingw32/include"
LDFLAGS="-L\"$(pwd)\"/i686-w64-mingw32/lib" ./configure 2>std.err | tee
std.out
```
This does not make nano build; `make` will end up in undefined references:
```text
gcc -g -O2 -Wall -L"/e/GitHub/nano-win"/i686-w64-mingw32/lib -o
nano.exe browser.o chars.o color.o cut.o files.o global.o help.o
history.o move.o nano.o prompt.o rcfile.o search.o text.o utils.o
winio.o ../lib/libgnu.a -pthread -lz -LC:/MinGW/MSYS2/mingw32/lib
-lncursesw
text.o: In function `do_formatter':
E:\GitHub\nano-win\src/text.c:3448: undefined reference to `fork'
E:\GitHub\nano-win\src/text.c:3470: undefined reference to `wait'
E:\GitHub\nano-win\src/text.c:3472: undefined reference to `WIFEXITED'
E:\GitHub\nano-win\src/text.c:3472: undefined reference to `WEXITSTATUS'
E:\GitHub\nano-win\src/text.c:3506: undefined reference to `WIFEXITED'
E:\GitHub\nano-win\src/text.c:3506: undefined reference to `WEXITSTATUS'
collect2.exe: error: ld returned 1 exit status
make[2]: *** [Makefile:1541: nano.exe] Error 1
make[2]: Leaving directory '/e/GitHub/nano-win/src'
make[1]: *** [Makefile:1543: all-recursive] Error 1
make[1]: Leaving directory '/e/GitHub/nano-win'
make: *** [Makefile:1482: all] Error 2
```
In order to build nano successfully, `--disable-speller` has to be
passed to `configure` due to absence of `fork()` and `wait()`.
>> Is the function `fixbounds()` really necessary today? \< and \> are
>> documented on <http://www.bsd.org/regexintro.html> (see chapter
>> Anchors), notwithstanding the absence of alternatives to \`.
>
> Is that web page valid for all BSDs? Because I can find \< and \> for
> FreeBSD and OpenBSD:
>
I don't know. I am not a BSD user. I know about Linux and Windows only.
>
> https://docs.freebsd.org/info/regex/regex.info.The_Backslash_Character.html
> https://man.openbsd.org/regex
>
> But NetBSD seems to know only [[:<:]] and [[:>:]]:
>
> http://netbsd.gw.com/cgi-bin/man-cgi?re_format+7+NetBSD-current
>
> And it seems FreeBSD will lose the GNU extensions in the future:
>
> https://wiki.freebsd.org/LibRegex
>
> Benno
--
Best regards,
LH_Mouse
outputs.tar.gz
Description: application/gzip
- [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/10
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Liu Hao, 2017/12/13
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/17
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Liu Hao, 2017/12/18
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/19
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Liu Hao, 2017/12/19
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/20
- Message not available
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/21
- Message not available
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Benno Schulenberg, 2017/12/25
- Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives,
Liu Hao <=
- [Nano-devel] build issues on Mingw32, Benno Schulenberg, 2017/12/26
- Re: [Nano-devel] build issues on Mingw32, Liu Hao, 2017/12/26
- Re: [Nano-devel] build issues on Mingw32, Benno Schulenberg, 2017/12/26
Re: [Nano-devel] [PATCH] syntax: c: change the highlighting of preprocessor directives, Liu Hao, 2017/12/13