pkgsrc-Users archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
Re: focuswriter build issue on 9 only
------- Original Message -------
On Friday, September 15th, 2023 at 6:48 PM, Niclas Rosenvik <nros%netbsd.org@localhost> wrote:
> On Fri, 15 Sep 2023 09:04:12 +0000
> pin voidpin%protonmail.com@localhost wrote:
>
> > Hi all,
> >
> > Could someone shed some light as how to solve the build of
> > editors/focuswriter on NetBSD-9? It currently fails on mef@
> > bulkbuilds at the configure stage with,
> >
> > -- Performing Test Iconv_IS_BUILT_IN
> > -- Performing Test Iconv_IS_BUILT_IN - Failed
> > CMake Error at
> > /usr/pkg/share/cmake-3.27/Modules/FindPackageHandleStandardArgs.cmake:230
> > (message): Could NOT find Iconv (missing: Iconv_LIBRARY) Call Stack
> > (most recent call first):
> > /usr/pkg/share/cmake-3.27/Modules/FindPackageHandleStandardArgs.cmake:600
> > (_FPHSA_FAILURE_MESSAGE)
> > /usr/pkg/share/cmake-3.27/Modules/FindIconv.cmake:165
> > (find_package_handle_standard_args) CMakeLists.txt:23 (find_package)
> >
> > -- Configuring incomplete, errors occurred!
> > *** Error code 1
> >
> > On my machine (amd64) running 10.99.8 from the 9th of September it
> > builds just fine.
> >
> > I've discussed this on a private thread with wiz@ that has suggested
> > that "perhaps the prototype for iconv() that was changed in -current
> > to be less correct but more like other implementations." is the cause
> > of it.
> >
> > Indeed from from
> > work/focuswriter-1.8.5/cmake-pkgsrc-build/CMakeFiles/CMakeConfigureLog.yaml
> >
> > /usr/pkgsrc/editors/focuswriter/work/focuswriter-1.8.5/cmake-pkgsrc-build/CMakeFiles/CMakeScratch/TryCompile-hv9FEC/src.cxx:
> > In function 'int main()':
> > /usr/pkgsrc/editors/focuswriter/work/focuswriter-1.8.5/cmake-pkgsrc-build/CMakeFiles/CMakeScratch/TryCompile-hv9FEC/src.cxx:9:19:
> > error: invalid conversion from 'char**' to 'const char**'
> > [-fpermissive] 9 | iconv(ic, &a, &i, &b, &j); |
> > ^~ | | | char**
> > In file included from
> > /usr/pkgsrc/editors/focuswriter/work/focuswriter-1.8.5/cmake-pkgsrc-build/CMakeFiles/CMakeScratch/TryCompile-hv9FEC/src.cxx:3:
> > /usr/include/iconv.h:46:23: note: initializing argument 2 of
> > 'size_t iconv(iconv_t, const char**, size_t*, char**, size_t*)' 46 |
> > size_t iconv(iconv_t, const char ** __restrict, |
> > ^
> >
> > But, we don't really know how to fix it or work around this.
> >
> > Thank you!
> > /Pedro
> >
> > Sent with Proton Mail secure email.
>
>
> Hi wiz and pin, I just took a look at this and the CMake FindICONV
> module Iconv_IS_BUILT_IN test has a section that looks like this:
> ------------------------------------------------------------------
> if(CMAKE_C_COMPILER_LOADED)
> check_c_source_compiles...
> else()
> check_cxx_source_compiles...
> endif()
> ------------------------------------------------------------------
> I tested to add C to the project command in CMakeLists.txt and c to
> USE_LANGUAGES in the pkgsrc Makefile and the test compiles. Well C++
> seems a lot more picky about const correctness than C is.
> The conclusion is that packages that uses CMake and FindICONV need C
> to build on NetBSD 9.
> Since FindICONV does not provide a define like ICONV_CONST from
> autotools, NetBSD const has to be checked for in the code instead.
> I have committed patches for the things mentioned above, so
> focuswriter should now build on NetBSD 9.
>
> Regards,
> Niclas
Thank you :3
(Tack ska du ha)
/Pedro
Home |
Main Index |
Thread Index |
Old Index