Re: 2.3.x does not compile on Windows

2024-05-02 Thread Richard Kimberly Heck

On 5/2/24 08:53, Pavel Sanda wrote:

On Wed, May 01, 2024 at 09:10:17PM +0200, Jean-Marc Lasgouttes wrote:

Le 01/05/2024 ?? 20:55, Yu Jin a écrit :

Am Mi., 1. Mai 2024 um 18:53 Uhr schrieb Jean-Marc Lasgouttes:

Le 01/05/2024 ?? 17:50, Yu Jin a écrit :
 > You are right, simply adding
 > #include 
 > to Format.cpp resolves the errors.

Great!


May I push it into the 2.3.x branch?

I think you can, unless there are more complicated changes than that.

This is great news. I think we are ready to push 2.3.8 out then, right?


Should be. Let me double check on the list and, if so

Riki


--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-02 Thread Pavel Sanda
On Wed, May 01, 2024 at 09:10:17PM +0200, Jean-Marc Lasgouttes wrote:
> Le 01/05/2024 ?? 20:55, Yu Jin a écrit :
> >Am Mi., 1. Mai 2024 um 18:53 Uhr schrieb Jean-Marc Lasgouttes:
> >
> >Le 01/05/2024 ?? 17:50, Yu Jin a écrit :
> > > You are right, simply adding
> > > #include 
> > > to Format.cpp resolves the errors.
> >
> >Great!
> >
> >
> >May I push it into the 2.3.x branch?
> 
> I think you can, unless there are more complicated changes than that.

This is great news. I think we are ready to push 2.3.8 out then, right?

Pavel
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Jean-Marc Lasgouttes

Le 01/05/2024 à 20:55, Yu Jin a écrit :

Am Mi., 1. Mai 2024 um 18:53 Uhr schrieb Jean-Marc Lasgouttes:

Le 01/05/2024 à 17:50, Yu Jin a écrit :
 > You are right, simply adding
 > #include 
 > to Format.cpp resolves the errors.

Great!


May I push it into the 2.3.x branch?


I think you can, unless there are more complicated changes than that.

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Yu Jin
Am Mi., 1. Mai 2024 um 18:53 Uhr schrieb Jean-Marc Lasgouttes:

> Le 01/05/2024 à 17:50, Yu Jin a écrit :
> > You are right, simply adding
> > #include 
> > to Format.cpp resolves the errors.
>
> Great!
>

May I push it into the 2.3.x branch?
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Jean-Marc Lasgouttes

Le 01/05/2024 à 17:50, Yu Jin a écrit :

You are right, simply adding
#include 
to Format.cpp resolves the errors.


Great!

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Yu Jin
Am Mi., 1. Mai 2024 um 13:36 Uhr schrieb Jean-Marc Lasgouttes:

> Le 01/05/2024 à 13:32, Jean-Marc Lasgouttes a écrit :
> > Le 01/05/2024 à 11:54, Yu Jin a écrit :
> >> 2.4 compiles with c++20 standard. The Problem with 2.3 are the
> >> "unary_function"s, which seem to require c++11(?) and as far as I can
> >> see the current Visual Studio just can not do that, c++14 is minimum.
> >
> > Reading this:
> >https://en.cppreference.com/w/cpp/utility/functional/unary_function
> > I would think that it works with C++14 and was remove din C++17 only.
>
> Actually, the function is in , which is not included in
> Format.cpp.
>
>
> https://learn.microsoft.com/en-us/answers/questions/1348183/std-binary-function-is-missing-in-msvc-14-37-32822


You are right, simply adding
#include 
to Format.cpp resolves the errors.
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Jean-Marc Lasgouttes

Le 01/05/2024 à 13:32, Jean-Marc Lasgouttes a écrit :

Le 01/05/2024 à 11:54, Yu Jin a écrit :
2.4 compiles with c++20 standard. The Problem with 2.3 are the 
"unary_function"s, which seem to require c++11(?) and as far as I can 
see the current Visual Studio just can not do that, c++14 is minimum.


Reading this:
   https://en.cppreference.com/w/cpp/utility/functional/unary_function
I would think that it works with C++14 and was remove din C++17 only.


Actually, the function is in , which is not included in 
Format.cpp.


https://learn.microsoft.com/en-us/answers/questions/1348183/std-binary-function-is-missing-in-msvc-14-37-32822

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Jean-Marc Lasgouttes

Le 01/05/2024 à 11:54, Yu Jin a écrit :
2.4 compiles with c++20 standard. The Problem with 2.3 are the 
"unary_function"s, which seem to require c++11(?) and as far as I can 
see the current Visual Studio just can not do that, c++14 is minimum.


Reading this:
  https://en.cppreference.com/w/cpp/utility/functional/unary_function
I would think that it works with C++14 and was remove din C++17 only.

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-05-01 Thread Yu Jin
Am Fr., 19. Apr. 2024 um 11:00 Uhr schrieb Kornel Benko :

> Am Thu, 18 Apr 2024 16:43:25 +0200
> schrieb Pavel Sanda:
>
> > On Wed, Apr 17, 2024 at 09:22:34AM +0200, Kornel Benko wrote:
> > > Am Tue, 16 Apr 2024 15:54:26 +0200
> > > schrieb Yu Jin:
> > >
> > > > > Alternatively you can try setting CMAKE_CXX_STANDARD directly.
> > > > > Like in CMakeLists.txt:646
> > > > > -if(NOT MSVC)
> > > > > +if (MSVC)
> > > > > +   set(CMAKE_CXX_STANDARD 11)
> > > > > +else()
> > > > >
> > > > > Since I cannot test for MSVC, it is untested.
> > > > >
> > > > Does not seem to do anything, the standard set in Visual Studio is
> still "Default
> > > > (C++14)" and still the same error occurs.
> > > >
> > >
> > > Sorry Eugene, I would try to check for diff of the used cxx parameters
> in lyx2.3 and
> > > lyx2.5 compilation. Other than that, I am out of suggestions.
> >
> > If we run out of ideas how to compile 2.3 with the current win compilers,
> > how hard or complex patches would be backporting compilation fixes
> present
> > in 2.4?
> >
> > Pavel
>
> Looks like not so easy. The changes in are
> development/cmake/modules/LyXMacros.cmake: easy managable
> development/cmake/modules/FindCXX11Compiler.cmake: looks not
> difficult
> CMakeLists.txt: Huge
>
> If Eugene is able to compile lyx2.4 with qt5

Yes I am.

> then I'd still like to know the
> differences of the used cxx parameters.

2.4 compiles with c++20 standard. The Problem with 2.3 are the
"unary_function"s, which seem to require c++11(?) and as far as I can see
the current Visual Studio just can not do that, c++14 is minimum.

> Seems easier to make a patch then (at least for
> Eugene's compiler)

-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-19 Thread Pavel Sanda
On Fri, Apr 19, 2024 at 12:52:06PM +0200, Jean-Marc Lasgouttes wrote:
> Le 19/04/2024 ?? 11:12, Pavel Sanda a écrit :
> >On Fri, Apr 19, 2024 at 11:03:55AM +0200, Kornel Benko wrote:
> >>Looks like not so easy. The changes in are
> >>development/cmake/modules/LyXMacros.cmake: easy managable
> >>development/cmake/modules/FindCXX11Compiler.cmake: looks not difficult
> >>CMakeLists.txt: Huge
> >
> >I thought the changes wouldn't be done in cmake, but in .cpp code,
> >like getting rid of unary_function reported in the begininng of
> >this thread, which we presumably don't use in 2.4 anymore(?).
> 
> I thought about backporting those, but they do not apply cleanly to 2.3, so
> that there is a risk of breaking code (just because a compiler decides to be
> a PITA).
> 
> Normally, we have correct C++11 code, we should be able to compile it in
> C++11 mode (even C++14 would do).

Well, we are not. What about the terrific option of just taking 2.3.7
win binaries, wrap it with 2.4->2.3 lyx2lyx python scripts, release
that as 2.3.7.2 (for win only) and the rest would go as 2.3.8.

The pool of prospective 2.3.8 win users once 2.4 is out would be negligible 
anyway.

Pavel
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-19 Thread Jean-Marc Lasgouttes

Le 19/04/2024 à 11:12, Pavel Sanda a écrit :

On Fri, Apr 19, 2024 at 11:03:55AM +0200, Kornel Benko wrote:

Looks like not so easy. The changes in are
development/cmake/modules/LyXMacros.cmake: easy managable
development/cmake/modules/FindCXX11Compiler.cmake: looks not difficult
CMakeLists.txt: Huge


I thought the changes wouldn't be done in cmake, but in .cpp code,
like getting rid of unary_function reported in the begininng of
this thread, which we presumably don't use in 2.4 anymore(?).


I thought about backporting those, but they do not apply cleanly to 2.3, 
so that there is a risk of breaking code (just because a compiler 
decides to be a PITA).


Normally, we have correct C++11 code, we should be able to compile it in 
C++11 mode (even C++14 would do).


JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-19 Thread Kornel Benko
Am Fri, 19 Apr 2024 11:12:41 +0200
schrieb Pavel Sanda :

> On Fri, Apr 19, 2024 at 11:03:55AM +0200, Kornel Benko wrote:
> > Looks like not so easy. The changes in are
> > development/cmake/modules/LyXMacros.cmake: easy managable
> > development/cmake/modules/FindCXX11Compiler.cmake: looks not difficult
> > CMakeLists.txt: Huge  
> 
> I thought the changes wouldn't be done in cmake, but in .cpp code,
> like getting rid of unary_function reported in the begininng of
> this thread, which we presumably don't use in 2.4 anymore(?).
> 
> Pavel

I'd prefer that too of course. But the settings for std= are done in cmake.
(Setting to C++11 was/is not successful)

Kornel


pgpOcuJBcdt7R.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-19 Thread Pavel Sanda
On Fri, Apr 19, 2024 at 11:03:55AM +0200, Kornel Benko wrote:
> Looks like not so easy. The changes in are
>   development/cmake/modules/LyXMacros.cmake: easy managable
>   development/cmake/modules/FindCXX11Compiler.cmake: looks not difficult
>   CMakeLists.txt: Huge

I thought the changes wouldn't be done in cmake, but in .cpp code,
like getting rid of unary_function reported in the begininng of
this thread, which we presumably don't use in 2.4 anymore(?).

Pavel
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-19 Thread Kornel Benko
Am Thu, 18 Apr 2024 16:43:25 +0200
schrieb Pavel Sanda :

> On Wed, Apr 17, 2024 at 09:22:34AM +0200, Kornel Benko wrote:
> > Am Tue, 16 Apr 2024 15:54:26 +0200
> > schrieb Yu Jin :
> >   
> > > > Alternatively you can try setting CMAKE_CXX_STANDARD directly.
> > > > Like in CMakeLists.txt:646
> > > > -if(NOT MSVC)
> > > > +if (MSVC)
> > > > +       set(CMAKE_CXX_STANDARD 11)
> > > > +else()
> > > > 
> > > > Since I cannot test for MSVC, it is untested.
> > > >   
> > > Does not seem to do anything, the standard set in Visual Studio is still 
> > > "Default
> > > (C++14)" and still the same error occurs. 
> > >   
> > 
> > Sorry Eugene, I would try to check for diff of the used cxx parameters in 
> > lyx2.3 and
> > lyx2.5 compilation. Other than that, I am out of suggestions.  
> 
> If we run out of ideas how to compile 2.3 with the current win compilers,
> how hard or complex patches would be backporting compilation fixes present
> in 2.4?
> 
> Pavel

Looks like not so easy. The changes in are
development/cmake/modules/LyXMacros.cmake: easy managable
development/cmake/modules/FindCXX11Compiler.cmake: looks not difficult
CMakeLists.txt: Huge

If Eugene is able to compile lyx2.4 with qt5 then I'd still like to know the
differences of the used cxx parameters. Seems easier to make a patch then (at 
least for
Eugene's compiler)

Kornel




pgpK8VMiGdsWO.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-18 Thread Pavel Sanda
On Wed, Apr 17, 2024 at 09:22:34AM +0200, Kornel Benko wrote:
> Am Tue, 16 Apr 2024 15:54:26 +0200
> schrieb Yu Jin :
> 
> > > Alternatively you can try setting CMAKE_CXX_STANDARD directly.
> > > Like in CMakeLists.txt:646
> > > -if(NOT MSVC)
> > > +if (MSVC)
> > > +       set(CMAKE_CXX_STANDARD 11)
> > > +else()
> > > 
> > > Since I cannot test for MSVC, it is untested.
> > > 
> > Does not seem to do anything, the standard set in Visual Studio is still 
> > "Default
> > (C++14)" and still the same error occurs. 
> > 
> 
> Sorry Eugene, I would try to check for diff of the used cxx parameters in 
> lyx2.3 and
> lyx2.5 compilation. Other than that, I am out of suggestions.

If we run out of ideas how to compile 2.3 with the current win compilers,
how hard or complex patches would be backporting compilation fixes present
in 2.4?

Pavel
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-17 Thread Kornel Benko
Am Tue, 16 Apr 2024 15:54:26 +0200
schrieb Yu Jin :

> > Alternatively you can try setting CMAKE_CXX_STANDARD directly.
> > Like in CMakeLists.txt:646
> > -if(NOT MSVC)
> > +if (MSVC)
> > +       set(CMAKE_CXX_STANDARD 11)
> > +else()
> > 
> > Since I cannot test for MSVC, it is untested.
> > 
> Does not seem to do anything, the standard set in Visual Studio is still 
> "Default
> (C++14)" and still the same error occurs. 
> 

Sorry Eugene, I would try to check for diff of the used cxx parameters in 
lyx2.3 and
lyx2.5 compilation. Other than that, I am out of suggestions.

Kornel


pgpYKe9Emn2GK.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-16 Thread Yu Jin
Am Di., 16. Apr. 2024 um 14:14 Uhr schrieb Kornel Benko:

> Am Fri, 12 Apr 2024 21:50:28 +0200
> schrieb Yu Jin:
>
> > Am Fr., 12. Apr. 2024 um 09:56 Uhr schrieb Kornel Benko:
> >
> > > Am Thu, 11 Apr 2024 17:13:20 +0200
> > > schrieb Yu Jin:
> > >
> > > > Am Do., 11. Apr. 2024 um 10:17 Uhr schrieb Kornel Benko:
> > > >
> > > > > Am Wed, 10 Apr 2024 21:02:40 +0200
> > > > > schrieb Yu Jin:
> > > > >
> > >
> > > [snip]
> > >
> > > > > Please check ./development/cmake/modules/LyXMacros.cmake:471
> > > > >
> > > >
> > > > On the 2.3.x branch there LyXMacros.cmake file only contains  403
> lines.
> > > >
> > >
> > >
> > > I completely forgot the 2.3 branch.
> > >
> > > Please check development/cmake/modules/FindCXX11Compiler.cmake:47
> > > and set CXX11_FLAG_CANDIDATES appropriate.
> > > (You may also look at
> > > # git log development/cmake/modules/FindCXX11Compiler.cmake
> > > in lyx2.4 for changes prior to 2ec243d47)
> >
> >
> > I either don't understand what I need to do or it does not help either. I
> > put "--std=c++11" in there but it did not help, still the same error.
>
> Alternatively you can try setting CMAKE_CXX_STANDARD directly.
> Like in CMakeLists.txt:646
> -if(NOT MSVC)
> +if (MSVC)
> +   set(CMAKE_CXX_STANDARD 11)
> +else()
>
> Since I cannot test for MSVC, it is untested.
>

Does not seem to do anything, the standard set in Visual Studio is still
"Default (C++14)" and still the same error occurs.


-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-16 Thread Kornel Benko
Am Fri, 12 Apr 2024 21:50:28 +0200
schrieb Yu Jin :

> Am Fr., 12. Apr. 2024 um 09:56 Uhr schrieb Kornel Benko :
> 
> > Am Thu, 11 Apr 2024 17:13:20 +0200
> > schrieb Yu Jin:
> >
> > > Am Do., 11. Apr. 2024 um 10:17 Uhr schrieb Kornel Benko:
> > >
> > > > Am Wed, 10 Apr 2024 21:02:40 +0200
> > > > schrieb Yu Jin:
> > > >
> >
> > [snip]
> >
> > > > Please check ./development/cmake/modules/LyXMacros.cmake:471
> > > >
> > >
> > > On the 2.3.x branch there LyXMacros.cmake file only contains  403 lines.
> > >
> >
> >
> > I completely forgot the 2.3 branch.
> >
> > Please check development/cmake/modules/FindCXX11Compiler.cmake:47
> > and set CXX11_FLAG_CANDIDATES appropriate.
> > (You may also look at
> > # git log development/cmake/modules/FindCXX11Compiler.cmake
> > in lyx2.4 for changes prior to 2ec243d47)
> 
> 
> I either don't understand what I need to do or it does not help either. I
> put "--std=c++11" in there but it did not help, still the same error.

Alternatively you can try setting CMAKE_CXX_STANDARD directly.
Like in CMakeLists.txt:646
-if(NOT MSVC)
+if (MSVC)
+   set(CMAKE_CXX_STANDARD 11)
+else()

Since I cannot test for MSVC, it is untested.

Kornel


pgpGK_2rdgEf1.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-12 Thread Yu Jin
Am Fr., 12. Apr. 2024 um 09:56 Uhr schrieb Kornel Benko :

> Am Thu, 11 Apr 2024 17:13:20 +0200
> schrieb Yu Jin:
>
> > Am Do., 11. Apr. 2024 um 10:17 Uhr schrieb Kornel Benko:
> >
> > > Am Wed, 10 Apr 2024 21:02:40 +0200
> > > schrieb Yu Jin:
> > >
>
> [snip]
>
> > > Please check ./development/cmake/modules/LyXMacros.cmake:471
> > >
> >
> > On the 2.3.x branch there LyXMacros.cmake file only contains  403 lines.
> >
>
>
> I completely forgot the 2.3 branch.
>
> Please check development/cmake/modules/FindCXX11Compiler.cmake:47
> and set CXX11_FLAG_CANDIDATES appropriate.
> (You may also look at
> # git log development/cmake/modules/FindCXX11Compiler.cmake
> in lyx2.4 for changes prior to 2ec243d47)


I either don't understand what I need to do or it does not help either. I
put "--std=c++11" in there but it did not help, still the same error.
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-12 Thread Kornel Benko
Am Thu, 11 Apr 2024 17:13:20 +0200
schrieb Yu Jin :

> Am Do., 11. Apr. 2024 um 10:17 Uhr schrieb Kornel Benko :
> 
> > Am Wed, 10 Apr 2024 21:02:40 +0200
> > schrieb Yu Jin :
> >

[snip]

> > Please check ./development/cmake/modules/LyXMacros.cmake:471
> >
> 
> On the 2.3.x branch there LyXMacros.cmake file only contains  403 lines.
> 


I completely forgot the 2.3 branch.

Please check development/cmake/modules/FindCXX11Compiler.cmake:47
and set CXX11_FLAG_CANDIDATES appropriate.
(You may also look at
# git log development/cmake/modules/FindCXX11Compiler.cmake
in lyx2.4 for changes prior to 2ec243d47)


Kornel


pgpymarfqci1d.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-11 Thread Yu Jin
Am Do., 11. Apr. 2024 um 10:17 Uhr schrieb Kornel Benko :

> Am Wed, 10 Apr 2024 21:02:40 +0200
> schrieb Yu Jin :
>
> > Am Mi., 10. Apr. 2024 um 16:02 Uhr schrieb Jean-Marc Lasgouttes :
> >
> > > Le 09/04/2024 à 06:30, Yu Jin a écrit :
> > > > Normally, unary_function and binary_function only disappeared in
> > > C++17.
> > > > Does C++14 work?
> > > >
> > > > Unfortunately not.
> > >
> > > Do you select the C++ level in Visual Studio or in cmake?
> > >
> >
> > I don't see any option in CMake regarding c++ level, I just execute
> > configure and as far as I can see it does not set any explicit c++ level
> > and default in the current Visual Studio is c++14 and there seems no way
> to
> > use c++11.
> >
> https://developercommunity.visualstudio.com/t/Need-C11-in-visual-studio-not-C11-or/10081597?space=8=idea=visualizer
> > Manually setting '/std:c++11' command line switch also does not work, it
> > actually says that this switch is unknown and will be ignored -> so again
> > c++14 is used. And installing an older Visual Studio (Community) is also
> > not an option, because Microsoft does not offer that (only Professional
> and
> > Enterprise), so rip lyX 2.3.8 on Windows I guess, unless someone decides
> to
> > cross compile it using MinGW or so.
>
>
> Please check ./development/cmake/modules/LyXMacros.cmake:471
>

On the 2.3.x branch there LyXMacros.cmake file only contains  403 lines.

In the function lyxgetknowncmakestd() we use the info from cmake to get the
> correct c++
> level (if the cmake version >= 3.9)
>

On the 2.3.x branch I can't find any "lyxgetknowncmakestd".
I have CMake 3.28.0

>
> OTOH, if your cmake version is less 3.9, we try to check for 98, 11 and 14.
> If that is the case for you, you could select your own values.
>


-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-11 Thread Kornel Benko
Am Wed, 10 Apr 2024 21:02:40 +0200
schrieb Yu Jin :

> Am Mi., 10. Apr. 2024 um 16:02 Uhr schrieb Jean-Marc Lasgouttes :
> 
> > Le 09/04/2024 à 06:30, Yu Jin a écrit :
> > > Normally, unary_function and binary_function only disappeared in
> > C++17.
> > > Does C++14 work?
> > >
> > > Unfortunately not.
> >
> > Do you select the C++ level in Visual Studio or in cmake?
> >
> 
> I don't see any option in CMake regarding c++ level, I just execute
> configure and as far as I can see it does not set any explicit c++ level
> and default in the current Visual Studio is c++14 and there seems no way to
> use c++11.
> https://developercommunity.visualstudio.com/t/Need-C11-in-visual-studio-not-C11-or/10081597?space=8=idea=visualizer
> Manually setting '/std:c++11' command line switch also does not work, it
> actually says that this switch is unknown and will be ignored -> so again
> c++14 is used. And installing an older Visual Studio (Community) is also
> not an option, because Microsoft does not offer that (only Professional and
> Enterprise), so rip lyX 2.3.8 on Windows I guess, unless someone decides to
> cross compile it using MinGW or so.


Please check ./development/cmake/modules/LyXMacros.cmake:471
In the function lyxgetknowncmakestd() we use the info from cmake to get the 
correct c++
level (if the cmake version >= 3.9)

OTOH, if your cmake version is less 3.9, we try to check for 98, 11 and 14.
If that is the case for you, you could select your own values.

Kornel


pgphhlqi4rKM7.pgp
Description: Digitale Signatur von OpenPGP
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-10 Thread Yu Jin
Am Mi., 10. Apr. 2024 um 16:02 Uhr schrieb Jean-Marc Lasgouttes :

> Le 09/04/2024 à 06:30, Yu Jin a écrit :
> > Normally, unary_function and binary_function only disappeared in
> C++17.
> > Does C++14 work?
> >
> > Unfortunately not.
>
> Do you select the C++ level in Visual Studio or in cmake?
>

I don't see any option in CMake regarding c++ level, I just execute
configure and as far as I can see it does not set any explicit c++ level
and default in the current Visual Studio is c++14 and there seems no way to
use c++11.
https://developercommunity.visualstudio.com/t/Need-C11-in-visual-studio-not-C11-or/10081597?space=8=idea=visualizer
Manually setting '/std:c++11' command line switch also does not work, it
actually says that this switch is unknown and will be ignored -> so again
c++14 is used. And installing an older Visual Studio (Community) is also
not an option, because Microsoft does not offer that (only Professional and
Enterprise), so rip lyX 2.3.8 on Windows I guess, unless someone decides to
cross compile it using MinGW or so.
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-10 Thread Jean-Marc Lasgouttes

Le 09/04/2024 à 06:30, Yu Jin a écrit :

Normally, unary_function and binary_function only disappeared in C++17.
Does C++14 work?

Unfortunately not.


Do you select the C++ level in Visual Studio or in cmake?

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-08 Thread Yu Jin
Am Mo., 8. Apr. 2024 um 22:05 Uhr schrieb Jean-Marc Lasgouttes:

> Le 08/04/2024 à 19:36, Yu Jin a écrit :
> > Can you try to enforce C++11 mode to see whether it works better?
> >
> >
> > That's a problem, I am not able to select C++11:
> > image.png
> > even installed an older Windows SDK and ran CMake reconfigure completely
> > new.
>
> Normally, unary_function and binary_function only disappeared in C++17.
> Does C++14 work?
>
Unfortunately not.
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-08 Thread Jean-Marc Lasgouttes

Le 08/04/2024 à 19:36, Yu Jin a écrit :

Can you try to enforce C++11 mode to see whether it works better?


That's a problem, I am not able to select C++11:
image.png
even installed an older Windows SDK and ran CMake reconfigure completely 
new.


Normally, unary_function and binary_function only disappeared in C++17. 
Does C++14 work?


JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-08 Thread Yu Jin
Am So., 7. Apr. 2024 um 20:40 Uhr schrieb Jean-Marc Lasgouttes <
lasgout...@lyx.org>:

> Le 05/04/2024 à 22:12, Yu Jin a écrit :
> > Hi,
> >
> > Since 2.3.8 is around the corner I thought to try compiling the 2.3.x
> > branch but failed on Format.cpp, get these errors:
> >
> > Build started at 22:05...
> > 1>-- Build started: Project: LyX (applications\LyX\LyX),
> > Configuration: Debug x64 --
> > 1>Format.cpp
> > 1>C:\lyx\master\src\Format.cpp(61,33): error C2504: 'unary_function':
> > base class undefined
> > 1>C:\lyx\master\src\Format.cpp(61,47): error C2143: syntax error:
> > missing ',' before '<'
> > 1>C:\lyx\master\src\Format.cpp(75,38): error C2504: 'unary_function':
> > base class undefined
> > 1>C:\lyx\master\src\Format.cpp(75,52): error C2143: syntax error:
> > missing ',' before '<'
> > 1>C:\lyx\master\src\Format.cpp(89,32): error C2504: 'unary_function':
> > base class undefined
> > 1>C:\lyx\master\src\Format.cpp(89,46): error C2143: syntax error:
> > missing ',' before '<'
> > 1>C:\lyx\master\src\Format.cpp(608,18): warning C4244: 'return':
> > conversion from '__int64' to 'int', possible loss of data
> > 1>Done building project "LyX.vcxproj" -- FAILED.
> > == Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped
> ==
> > == Build completed at 22:05 and took 00,762 seconds ==
> >
> > Any Ideas?
>
> Can you try to enforce C++11 mode to see whether it works better?


That's a problem, I am not able to select C++11:
[image: image.png]
even installed an older Windows SDK and ran CMake reconfigure completely
new.

-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


Re: 2.3.x does not compile on Windows

2024-04-07 Thread Jean-Marc Lasgouttes

Le 05/04/2024 à 22:12, Yu Jin a écrit :

Hi,

Since 2.3.8 is around the corner I thought to try compiling the 2.3.x 
branch but failed on Format.cpp, get these errors:


Build started at 22:05...
1>-- Build started: Project: LyX (applications\LyX\LyX), 
Configuration: Debug x64 --

1>Format.cpp
1>C:\lyx\master\src\Format.cpp(61,33): error C2504: 'unary_function': 
base class undefined
1>C:\lyx\master\src\Format.cpp(61,47): error C2143: syntax error: 
missing ',' before '<'
1>C:\lyx\master\src\Format.cpp(75,38): error C2504: 'unary_function': 
base class undefined
1>C:\lyx\master\src\Format.cpp(75,52): error C2143: syntax error: 
missing ',' before '<'
1>C:\lyx\master\src\Format.cpp(89,32): error C2504: 'unary_function': 
base class undefined
1>C:\lyx\master\src\Format.cpp(89,46): error C2143: syntax error: 
missing ',' before '<'
1>C:\lyx\master\src\Format.cpp(608,18): warning C4244: 'return': 
conversion from '__int64' to 'int', possible loss of data

1>Done building project "LyX.vcxproj" -- FAILED.
== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==
== Build completed at 22:05 and took 00,762 seconds ==

Any Ideas?


Can you try to enforce C++11 mode to see whether it works better?

JMarc

--
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel


2.3.x does not compile on Windows

2024-04-05 Thread Yu Jin
Hi,

Since 2.3.8 is around the corner I thought to try compiling the 2.3.x
branch but failed on Format.cpp, get these errors:

Build started at 22:05...
1>-- Build started: Project: LyX (applications\LyX\LyX), Configuration:
Debug x64 --
1>Format.cpp
1>C:\lyx\master\src\Format.cpp(61,33): error C2504: 'unary_function': base
class undefined
1>C:\lyx\master\src\Format.cpp(61,47): error C2143: syntax error: missing
',' before '<'
1>C:\lyx\master\src\Format.cpp(75,38): error C2504: 'unary_function': base
class undefined
1>C:\lyx\master\src\Format.cpp(75,52): error C2143: syntax error: missing
',' before '<'
1>C:\lyx\master\src\Format.cpp(89,32): error C2504: 'unary_function': base
class undefined
1>C:\lyx\master\src\Format.cpp(89,46): error C2143: syntax error: missing
',' before '<'
1>C:\lyx\master\src\Format.cpp(608,18): warning C4244: 'return': conversion
from '__int64' to 'int', possible loss of data
1>Done building project "LyX.vcxproj" -- FAILED.
== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==
== Build completed at 22:05 and took 00,762 seconds ==

Any Ideas?
-- 
  Eugene
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel