libosmscout-development Mailing List for libosmscout (Page 5)
Library for OpenStreetMap offline rendering and routing
Status: Beta
Brought to you by:
tteuling
You can subscribe to this list here.
2009 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
|
Sep
|
Oct
(4) |
Nov
|
Dec
|
---|---|---|---|---|---|---|---|---|---|---|---|---|
2010 |
Jan
|
Feb
|
Mar
|
Apr
(1) |
May
|
Jun
(15) |
Jul
|
Aug
|
Sep
(17) |
Oct
(1) |
Nov
(12) |
Dec
(14) |
2011 |
Jan
(13) |
Feb
(1) |
Mar
(26) |
Apr
(15) |
May
|
Jun
|
Jul
(1) |
Aug
|
Sep
(8) |
Oct
(9) |
Nov
(51) |
Dec
(17) |
2012 |
Jan
(45) |
Feb
(20) |
Mar
(117) |
Apr
(70) |
May
(19) |
Jun
(13) |
Jul
(17) |
Aug
(17) |
Sep
(35) |
Oct
(96) |
Nov
(27) |
Dec
(46) |
2013 |
Jan
(18) |
Feb
(64) |
Mar
(39) |
Apr
(23) |
May
(21) |
Jun
(10) |
Jul
(32) |
Aug
(8) |
Sep
(1) |
Oct
(19) |
Nov
(20) |
Dec
(44) |
2014 |
Jan
(28) |
Feb
(43) |
Mar
(53) |
Apr
(26) |
May
(15) |
Jun
(39) |
Jul
(8) |
Aug
(18) |
Sep
(27) |
Oct
(21) |
Nov
(11) |
Dec
(18) |
2015 |
Jan
(5) |
Feb
(1) |
Mar
(31) |
Apr
(20) |
May
(17) |
Jun
(24) |
Jul
(17) |
Aug
(27) |
Sep
(23) |
Oct
(28) |
Nov
(10) |
Dec
(22) |
2016 |
Jan
(8) |
Feb
(2) |
Mar
(52) |
Apr
(36) |
May
(14) |
Jun
(26) |
Jul
(50) |
Aug
(186) |
Sep
(100) |
Oct
(98) |
Nov
(106) |
Dec
(63) |
2017 |
Jan
(136) |
Feb
(71) |
Mar
(51) |
Apr
(27) |
May
(100) |
Jun
(80) |
Jul
(30) |
Aug
(39) |
Sep
(37) |
Oct
(17) |
Nov
(26) |
Dec
(33) |
2018 |
Jan
(15) |
Feb
(5) |
Mar
(8) |
Apr
(31) |
May
(33) |
Jun
(16) |
Jul
(9) |
Aug
(21) |
Sep
|
Oct
|
Nov
(42) |
Dec
(9) |
2019 |
Jan
(3) |
Feb
(3) |
Mar
|
Apr
(12) |
May
(25) |
Jun
(8) |
Jul
|
Aug
|
Sep
|
Oct
(7) |
Nov
|
Dec
|
2020 |
Jan
(4) |
Feb
(7) |
Mar
|
Apr
(15) |
May
(14) |
Jun
(15) |
Jul
(7) |
Aug
|
Sep
(4) |
Oct
(19) |
Nov
(2) |
Dec
(2) |
2021 |
Jan
|
Feb
|
Mar
(1) |
Apr
(19) |
May
(5) |
Jun
(2) |
Jul
(1) |
Aug
|
Sep
|
Oct
(1) |
Nov
|
Dec
(58) |
2022 |
Jan
(34) |
Feb
(2) |
Mar
|
Apr
(14) |
May
|
Jun
(4) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
2023 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
(5) |
Aug
(2) |
Sep
|
Oct
|
Nov
|
Dec
|
2024 |
Jan
(3) |
Feb
|
Mar
|
Apr
|
May
|
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
From: David H. R. <dav...@gm...> - 2021-12-23 12:51:05
|
I delete all the libos... directory and downloaded again. rebuild and now it works.... don't ask me why. BTW: how could I compile the library for x86 release or x64 release? thanks for your patience and time. On Thu, 23 Dec 2021 at 11:19, David Huelves Ramos <dav...@gm...> wrote: > > > On Wed, 22 Dec 2021 at 20:06, Tim Teulings <ti...@fr...> wrote: > >> Hello David, >> >> getting closer... >> >> From the code: >> >> #if defined(HAVE_LIB_PROTOBUF) || >> defined(OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT) >> PreprocessPBF preprocess(callback); >> >> if (!preprocess.Import(typeConfig, >> parameter, >> progress, >> filename)) { >> return false; >> } >> #else >> progress.Error("Support for the PBF file format is not >> enabled!"); >> return false; >> #endif >> >> > At this point "libosmscout\build\Import\include" > in the config file there is no PROBUF defined. > > > >> Frm Config.h (generated by build system) >> >> /* libprotobuf detected */ >> #ifndef HAVE_LIB_PROTOBUF >> #define HAVE_LIB_PROTOBUF 1 >> #endif >> >> and ImportFeatures.h (also generated, however only ocrrectly by the >> meson build system): >> >> /* *osm.pbf files can be imported */ >> #define OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT >> >> Can you please check your Config.h file >> (build/Import/include/osmscout/pivate/Config.h) if the macro is set. >> >> > [image: image.png] > > I can't find any definition of > "OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT" > > any tip on this? > > > >> Is is also possible that it fails at runtime (e.g. protobuf is available >> but not libz) , but in this case it seems like the support was not build >> in while the necessary libraries itself seem to have been found. >> >> Is PreprocessPBF.cpp and also the *.pb.* (fileformat.pb.cc and Co.) >> beeing build? >> >> Also at the end of the initial cmake call a resulting sttaus is dumped: >> >> ... >> if (OSMSCOUT_BUILD_IMPORT) >> message(STATUS " - libxml2 support: ${LIBXML2_FOUND}") >> message(STATUS " - protobuf support: ${PROTOBUF_FOUND}") >> message(STATUS " - C++17 parallel execution: >> ${HAVE_STD_EXECUTION}") >> endif() >> ... >> >> What is show in your case? It is possible that the library is found but >> not the protoc executable (for whatever reasons) and the the resulting >> status is still false. >> >> Am 22.12.21 um 19:21 schrieb David Huelves Ramos: >> > Well, >> > >> > I get this: >> > >> > image.png >> > >> > So it seems libs are ok. >> > >> > Then I compile with "cmake --build ." and everything is ok. >> > >> > I get Import.exe >> > and libosmcout-import libraries >> > >> > image.png >> > >> > But again, and I don't know why: >> > >> > image.png >> > >> > when I try to Import a .ost.pbf file I get the same error message. >> > >> > >> > >> > >> > On Wed, 22 Dec 2021 at 19:07, David Huelves Ramos >> > <dav...@gm... <mailto:dav...@gm...>> wrote: >> > >> > It seems that I had to get into the build dir and specify -S .. to >> > get it done. >> > >> > now is working on: "cmake --build ." from inside the build dir. >> > >> > I'll write you back after finished. >> > >> > On Wed, 22 Dec 2021 at 18:55, Tim Teulings <ti...@fr... >> > <mailto:ti...@fr...>> wrote: >> > >> > Hello David, >> > >> > > but don't know what does it mean. >> > >> > First the warning above: >> > >> > cmake likes to sepaeate the source directory and the build >> > directory. >> > Please create a build sub directory and call cmake from with in >> > this sub >> > directory (with .. as path to the root cmake file). This should >> > make the >> > warning go away. >> > >> > You should also cleanup the root directory from everything that >> > is not >> > part of the git content and that you did not create yourself >> > manually. >> > >> > As you can see from the output from the latest Windoes Visual >> > Studio >> > build on github >> > ( >> https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true >> > < >> https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true >> > >> > >> > (see section "Confiure build project") the start off the cmake >> > call is >> > different: >> > >> > 1s >> > 3s >> > 8s >> > 1s >> > 1m 19s >> > 3s >> > 0s >> > 2s >> > 1s >> > 1s >> > 2m 15s >> > Run cmake -G "Visual Studio 16 2019" -A x64 >> > -DOSMSCOUT_BUILD_DOC_API=OFF >> > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 >> > >> -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake >> > >> > -Wno-dev .. >> > -- Selecting Windows SDK version 10.0.22000.0 to target Windows >> 10. >> > -- The C compiler identification is MSVC 19.29.30138.0 >> > -- The CXX compiler identification is MSVC 19.29.30138.0 >> > -- Detecting C compiler ABI info >> > -- Detecting C compiler ABI info - done >> > -- Check for working C compiler: C:/Program Files >> > (x86)/Microsoft Visual >> > >> Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe >> > >> > - skipped >> > -- Detecting C compile features >> > -- Detecting C compile features - done >> > -- Detecting CXX compiler ABI info >> > -- Detecting CXX compiler ABI info - done >> > -- Check for working CXX compiler: C:/Program Files >> (x86)/Microsoft >> > Visual >> > >> Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe >> > >> > - skipped >> > -- Detecting CXX compile features >> > -- Detecting CXX compile features - done >> > -- Looking for dlfcn.h >> > -- Looking for dlfcn.h - not found >> > -- Looking for fcntl.h >> > -- Looking for fcntl.h - found >> > -- Looking for inttypes.h >> > -- Looking for inttypes.h - found >> > -- Looking for memory.h >> > -- Looking for memory.h - found >> > -- Looking for stdint.h >> > -- Looking for stdint.h - found >> > -- Looking for stdlib.h >> > -- Looking for stdlib.h - found >> > -- Looking for strings.h >> > -- Looking for strings.h - not found >> > -- Looking for string.h >> > -- Looking for string.h - found >> > -- Looking for sys/stat.h >> > -- Looking for sys/stat.h - found >> > -- Looking for sys/time.h >> > -- Looking for sys/time.h - not found >> > -- Looking for sys/types.h >> > -- Looking for sys/types.h - found >> > -- Looking for unistd.h >> > -- Looking for unistd.h - not found >> > -- Looking for C++ include codecvt >> > -- Looking for C++ include codecvt - found >> > -- Looking for stddef.h >> > -- Looking for stddef.h - found >> > -- Check size of int16_t >> > -- Check size of int16_t - done >> > -- Check size of int32_t >> > -- Check size of int32_t - done >> > -- Check size of int64_t >> > -- Check size of int64_t - done >> > -- Check size of int8_t >> > -- Check size of int8_t - done >> > -- Check size of long long >> > -- Check size of long long - done >> > -- Check size of uint16_t >> > -- Check size of uint16_t - done >> > -- Check size of uint32_t >> > -- Check size of uint32_t - done >> > -- Check size of uint64_t >> > -- Check size of uint64_t - done >> > -- Check size of uint8_t >> > -- Check size of uint8_t - done >> > -- Check size of unsigned long long >> > -- Check size of unsigned long long - done >> > -- Check size of wchar_t >> > -- Check size of wchar_t - done >> > -- Looking for fseeko >> > -- Looking for fseeko - not found >> > -- Looking for mmap >> > -- Looking for mmap - not found >> > -- Looking for posix_fadvise >> > -- Looking for posix_fadvise - not found >> > -- Looking for posix_madvise >> > -- Looking for posix_madvise - not found >> > -- Looking for mallinfo >> > -- Looking for mallinfo - not found >> > -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found >> > version >> > "0.26") >> > -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS >> > MARISA_LIBRARIES) >> > -- Found LibXml2: >> > >> D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib >> > >> > (found version "2.9.10") >> > -- Found Protobuf: >> > >> optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib >> > >> > (found version "3.15.8") >> > -- Found ZLIB: >> > >> optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib >> > >> > (found version "1.2.11") >> > ... >> > >> > Please show the start of your call output. I would like to see, >> > if SDK >> > and compiler were correctly found. If not, there is a script in >> the >> > Visual Studio compiler installation to be called (See for >> example >> > >> https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 >> > < >> https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 >> >). >> > >> > -- >> > Gruß... >> > Tim >> > >> > >> > >> > _______________________________________________ >> > Libosmscout-development mailing list >> > Lib...@li... >> > <mailto:Lib...@li...> >> > >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > < >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development> >> > >> > >> > >> > _______________________________________________ >> > Libosmscout-development mailing list >> > Lib...@li... >> > https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> >> -- >> Gruß... >> Tim >> >> >> >> _______________________________________________ >> Libosmscout-development mailing list >> Lib...@li... >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > |
From: David H. R. <dav...@gm...> - 2021-12-23 10:19:42
|
On Wed, 22 Dec 2021 at 20:06, Tim Teulings <ti...@fr...> wrote: > Hello David, > > getting closer... > > From the code: > > #if defined(HAVE_LIB_PROTOBUF) || > defined(OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT) > PreprocessPBF preprocess(callback); > > if (!preprocess.Import(typeConfig, > parameter, > progress, > filename)) { > return false; > } > #else > progress.Error("Support for the PBF file format is not enabled!"); > return false; > #endif > > At this point "libosmscout\build\Import\include" in the config file there is no PROBUF defined. > Frm Config.h (generated by build system) > > /* libprotobuf detected */ > #ifndef HAVE_LIB_PROTOBUF > #define HAVE_LIB_PROTOBUF 1 > #endif > > and ImportFeatures.h (also generated, however only ocrrectly by the > meson build system): > > /* *osm.pbf files can be imported */ > #define OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT > > Can you please check your Config.h file > (build/Import/include/osmscout/pivate/Config.h) if the macro is set. > > [image: image.png] I can't find any definition of "OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT" any tip on this? > Is is also possible that it fails at runtime (e.g. protobuf is available > but not libz) , but in this case it seems like the support was not build > in while the necessary libraries itself seem to have been found. > > Is PreprocessPBF.cpp and also the *.pb.* (fileformat.pb.cc and Co.) > beeing build? > > Also at the end of the initial cmake call a resulting sttaus is dumped: > > ... > if (OSMSCOUT_BUILD_IMPORT) > message(STATUS " - libxml2 support: ${LIBXML2_FOUND}") > message(STATUS " - protobuf support: ${PROTOBUF_FOUND}") > message(STATUS " - C++17 parallel execution: ${HAVE_STD_EXECUTION}") > endif() > ... > > What is show in your case? It is possible that the library is found but > not the protoc executable (for whatever reasons) and the the resulting > status is still false. > > Am 22.12.21 um 19:21 schrieb David Huelves Ramos: > > Well, > > > > I get this: > > > > image.png > > > > So it seems libs are ok. > > > > Then I compile with "cmake --build ." and everything is ok. > > > > I get Import.exe > > and libosmcout-import libraries > > > > image.png > > > > But again, and I don't know why: > > > > image.png > > > > when I try to Import a .ost.pbf file I get the same error message. > > > > > > > > > > On Wed, 22 Dec 2021 at 19:07, David Huelves Ramos > > <dav...@gm... <mailto:dav...@gm...>> wrote: > > > > It seems that I had to get into the build dir and specify -S .. to > > get it done. > > > > now is working on: "cmake --build ." from inside the build dir. > > > > I'll write you back after finished. > > > > On Wed, 22 Dec 2021 at 18:55, Tim Teulings <ti...@fr... > > <mailto:ti...@fr...>> wrote: > > > > Hello David, > > > > > but don't know what does it mean. > > > > First the warning above: > > > > cmake likes to sepaeate the source directory and the build > > directory. > > Please create a build sub directory and call cmake from with in > > this sub > > directory (with .. as path to the root cmake file). This should > > make the > > warning go away. > > > > You should also cleanup the root directory from everything that > > is not > > part of the git content and that you did not create yourself > > manually. > > > > As you can see from the output from the latest Windoes Visual > > Studio > > build on github > > ( > https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true > > < > https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true > > > > > > (see section "Confiure build project") the start off the cmake > > call is > > different: > > > > 1s > > 3s > > 8s > > 1s > > 1m 19s > > 3s > > 0s > > 2s > > 1s > > 1s > > 2m 15s > > Run cmake -G "Visual Studio 16 2019" -A x64 > > -DOSMSCOUT_BUILD_DOC_API=OFF > > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 > > > -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake > > > > -Wno-dev .. > > -- Selecting Windows SDK version 10.0.22000.0 to target Windows > 10. > > -- The C compiler identification is MSVC 19.29.30138.0 > > -- The CXX compiler identification is MSVC 19.29.30138.0 > > -- Detecting C compiler ABI info > > -- Detecting C compiler ABI info - done > > -- Check for working C compiler: C:/Program Files > > (x86)/Microsoft Visual > > > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > > > > - skipped > > -- Detecting C compile features > > -- Detecting C compile features - done > > -- Detecting CXX compiler ABI info > > -- Detecting CXX compiler ABI info - done > > -- Check for working CXX compiler: C:/Program Files > (x86)/Microsoft > > Visual > > > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > > > > - skipped > > -- Detecting CXX compile features > > -- Detecting CXX compile features - done > > -- Looking for dlfcn.h > > -- Looking for dlfcn.h - not found > > -- Looking for fcntl.h > > -- Looking for fcntl.h - found > > -- Looking for inttypes.h > > -- Looking for inttypes.h - found > > -- Looking for memory.h > > -- Looking for memory.h - found > > -- Looking for stdint.h > > -- Looking for stdint.h - found > > -- Looking for stdlib.h > > -- Looking for stdlib.h - found > > -- Looking for strings.h > > -- Looking for strings.h - not found > > -- Looking for string.h > > -- Looking for string.h - found > > -- Looking for sys/stat.h > > -- Looking for sys/stat.h - found > > -- Looking for sys/time.h > > -- Looking for sys/time.h - not found > > -- Looking for sys/types.h > > -- Looking for sys/types.h - found > > -- Looking for unistd.h > > -- Looking for unistd.h - not found > > -- Looking for C++ include codecvt > > -- Looking for C++ include codecvt - found > > -- Looking for stddef.h > > -- Looking for stddef.h - found > > -- Check size of int16_t > > -- Check size of int16_t - done > > -- Check size of int32_t > > -- Check size of int32_t - done > > -- Check size of int64_t > > -- Check size of int64_t - done > > -- Check size of int8_t > > -- Check size of int8_t - done > > -- Check size of long long > > -- Check size of long long - done > > -- Check size of uint16_t > > -- Check size of uint16_t - done > > -- Check size of uint32_t > > -- Check size of uint32_t - done > > -- Check size of uint64_t > > -- Check size of uint64_t - done > > -- Check size of uint8_t > > -- Check size of uint8_t - done > > -- Check size of unsigned long long > > -- Check size of unsigned long long - done > > -- Check size of wchar_t > > -- Check size of wchar_t - done > > -- Looking for fseeko > > -- Looking for fseeko - not found > > -- Looking for mmap > > -- Looking for mmap - not found > > -- Looking for posix_fadvise > > -- Looking for posix_fadvise - not found > > -- Looking for posix_madvise > > -- Looking for posix_madvise - not found > > -- Looking for mallinfo > > -- Looking for mallinfo - not found > > -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found > > version > > "0.26") > > -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS > > MARISA_LIBRARIES) > > -- Found LibXml2: > > > D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib > > > > (found version "2.9.10") > > -- Found Protobuf: > > > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib > > > > (found version "3.15.8") > > -- Found ZLIB: > > > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib > > > > (found version "1.2.11") > > ... > > > > Please show the start of your call output. I would like to see, > > if SDK > > and compiler were correctly found. If not, there is a script in > the > > Visual Studio compiler installation to be called (See for example > > > https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 > > < > https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 > >). > > > > -- > > Gruß... > > Tim > > > > > > > > _______________________________________________ > > Libosmscout-development mailing list > > Lib...@li... > > <mailto:Lib...@li...> > > > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > > < > https://lists.sourceforge.net/lists/listinfo/libosmscout-development> > > > > > > > > _______________________________________________ > > Libosmscout-development mailing list > > Lib...@li... > > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > > -- > Gruß... > Tim > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > |
From: Tim T. <ti...@fr...> - 2021-12-22 19:06:31
|
Hello David, getting closer... From the code: #if defined(HAVE_LIB_PROTOBUF) || defined(OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT) PreprocessPBF preprocess(callback); if (!preprocess.Import(typeConfig, parameter, progress, filename)) { return false; } #else progress.Error("Support for the PBF file format is not enabled!"); return false; #endif Frm Config.h (generated by build system) /* libprotobuf detected */ #ifndef HAVE_LIB_PROTOBUF #define HAVE_LIB_PROTOBUF 1 #endif and ImportFeatures.h (also generated, however only ocrrectly by the meson build system): /* *osm.pbf files can be imported */ #define OSMSCOUT_IMPORT_HAVE_PROTOBUF_SUPPORT Can you please check your Config.h file (build/Import/include/osmscout/pivate/Config.h) if the macro is set. Is is also possible that it fails at runtime (e.g. protobuf is available but not libz) , but in this case it seems like the support was not build in while the necessary libraries itself seem to have been found. Is PreprocessPBF.cpp and also the *.pb.* (fileformat.pb.cc and Co.) beeing build? Also at the end of the initial cmake call a resulting sttaus is dumped: ... if (OSMSCOUT_BUILD_IMPORT) message(STATUS " - libxml2 support: ${LIBXML2_FOUND}") message(STATUS " - protobuf support: ${PROTOBUF_FOUND}") message(STATUS " - C++17 parallel execution: ${HAVE_STD_EXECUTION}") endif() ... What is show in your case? It is possible that the library is found but not the protoc executable (for whatever reasons) and the the resulting status is still false. Am 22.12.21 um 19:21 schrieb David Huelves Ramos: > Well, > > I get this: > > image.png > > So it seems libs are ok. > > Then I compile with "cmake --build ." and everything is ok. > > I get Import.exe > and libosmcout-import libraries > > image.png > > But again, and I don't know why: > > image.png > > when I try to Import a .ost.pbf file I get the same error message. > > > > > On Wed, 22 Dec 2021 at 19:07, David Huelves Ramos > <dav...@gm... <mailto:dav...@gm...>> wrote: > > It seems that I had to get into the build dir and specify -S .. to > get it done. > > now is working on: "cmake --build ." from inside the build dir. > > I'll write you back after finished. > > On Wed, 22 Dec 2021 at 18:55, Tim Teulings <ti...@fr... > <mailto:ti...@fr...>> wrote: > > Hello David, > > > but don't know what does it mean. > > First the warning above: > > cmake likes to sepaeate the source directory and the build > directory. > Please create a build sub directory and call cmake from with in > this sub > directory (with .. as path to the root cmake file). This should > make the > warning go away. > > You should also cleanup the root directory from everything that > is not > part of the git content and that you did not create yourself > manually. > > As you can see from the output from the latest Windoes Visual > Studio > build on github > (https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true > <https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true> > > (see section "Confiure build project") the start off the cmake > call is > different: > > 1s > 3s > 8s > 1s > 1m 19s > 3s > 0s > 2s > 1s > 1s > 2m 15s > Run cmake -G "Visual Studio 16 2019" -A x64 > -DOSMSCOUT_BUILD_DOC_API=OFF > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 > -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake > > -Wno-dev .. > -- Selecting Windows SDK version 10.0.22000.0 to target Windows 10. > -- The C compiler identification is MSVC 19.29.30138.0 > -- The CXX compiler identification is MSVC 19.29.30138.0 > -- Detecting C compiler ABI info > -- Detecting C compiler ABI info - done > -- Check for working C compiler: C:/Program Files > (x86)/Microsoft Visual > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > > - skipped > -- Detecting C compile features > -- Detecting C compile features - done > -- Detecting CXX compiler ABI info > -- Detecting CXX compiler ABI info - done > -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft > Visual > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > > - skipped > -- Detecting CXX compile features > -- Detecting CXX compile features - done > -- Looking for dlfcn.h > -- Looking for dlfcn.h - not found > -- Looking for fcntl.h > -- Looking for fcntl.h - found > -- Looking for inttypes.h > -- Looking for inttypes.h - found > -- Looking for memory.h > -- Looking for memory.h - found > -- Looking for stdint.h > -- Looking for stdint.h - found > -- Looking for stdlib.h > -- Looking for stdlib.h - found > -- Looking for strings.h > -- Looking for strings.h - not found > -- Looking for string.h > -- Looking for string.h - found > -- Looking for sys/stat.h > -- Looking for sys/stat.h - found > -- Looking for sys/time.h > -- Looking for sys/time.h - not found > -- Looking for sys/types.h > -- Looking for sys/types.h - found > -- Looking for unistd.h > -- Looking for unistd.h - not found > -- Looking for C++ include codecvt > -- Looking for C++ include codecvt - found > -- Looking for stddef.h > -- Looking for stddef.h - found > -- Check size of int16_t > -- Check size of int16_t - done > -- Check size of int32_t > -- Check size of int32_t - done > -- Check size of int64_t > -- Check size of int64_t - done > -- Check size of int8_t > -- Check size of int8_t - done > -- Check size of long long > -- Check size of long long - done > -- Check size of uint16_t > -- Check size of uint16_t - done > -- Check size of uint32_t > -- Check size of uint32_t - done > -- Check size of uint64_t > -- Check size of uint64_t - done > -- Check size of uint8_t > -- Check size of uint8_t - done > -- Check size of unsigned long long > -- Check size of unsigned long long - done > -- Check size of wchar_t > -- Check size of wchar_t - done > -- Looking for fseeko > -- Looking for fseeko - not found > -- Looking for mmap > -- Looking for mmap - not found > -- Looking for posix_fadvise > -- Looking for posix_fadvise - not found > -- Looking for posix_madvise > -- Looking for posix_madvise - not found > -- Looking for mallinfo > -- Looking for mallinfo - not found > -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found > version > "0.26") > -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS > MARISA_LIBRARIES) > -- Found LibXml2: > D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib > > (found version "2.9.10") > -- Found Protobuf: > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib > > (found version "3.15.8") > -- Found ZLIB: > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib > > (found version "1.2.11") > ... > > Please show the start of your call output. I would like to see, > if SDK > and compiler were correctly found. If not, there is a script in the > Visual Studio compiler installation to be called (See for example > https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 > <https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019>). > > -- > Gruß... > Tim > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > <mailto:Lib...@li...> > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > <https://lists.sourceforge.net/lists/listinfo/libosmscout-development> > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development -- Gruß... Tim |
From: David H. R. <dav...@gm...> - 2021-12-22 18:22:03
|
Well, I get this: [image: image.png] So it seems libs are ok. Then I compile with "cmake --build ." and everything is ok. I get Import.exe and libosmcout-import libraries [image: image.png] But again, and I don't know why: [image: image.png] when I try to Import a .ost.pbf file I get the same error message. On Wed, 22 Dec 2021 at 19:07, David Huelves Ramos <dav...@gm...> wrote: > It seems that I had to get into the build dir and specify -S .. to get it > done. > > now is working on: "cmake --build ." from inside the build dir. > > I'll write you back after finished. > > On Wed, 22 Dec 2021 at 18:55, Tim Teulings <ti...@fr...> wrote: > >> Hello David, >> >> > but don't know what does it mean. >> >> First the warning above: >> >> cmake likes to sepaeate the source directory and the build directory. >> Please create a build sub directory and call cmake from with in this sub >> directory (with .. as path to the root cmake file). This should make the >> warning go away. >> >> You should also cleanup the root directory from everything that is not >> part of the git content and that you did not create yourself manually. >> >> As you can see from the output from the latest Windoes Visual Studio >> build on github >> ( >> https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true >> (see section "Confiure build project") the start off the cmake call is >> different: >> >> 1s >> 3s >> 8s >> 1s >> 1m 19s >> 3s >> 0s >> 2s >> 1s >> 1s >> 2m 15s >> Run cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF >> -DCMAKE_SYSTEM_VERSION=10.0.18362.0 >> -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake >> >> -Wno-dev .. >> -- Selecting Windows SDK version 10.0.22000.0 to target Windows 10. >> -- The C compiler identification is MSVC 19.29.30138.0 >> -- The CXX compiler identification is MSVC 19.29.30138.0 >> -- Detecting C compiler ABI info >> -- Detecting C compiler ABI info - done >> -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual >> Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe >> - skipped >> -- Detecting C compile features >> -- Detecting C compile features - done >> -- Detecting CXX compiler ABI info >> -- Detecting CXX compiler ABI info - done >> -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft >> Visual >> Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe >> - skipped >> -- Detecting CXX compile features >> -- Detecting CXX compile features - done >> -- Looking for dlfcn.h >> -- Looking for dlfcn.h - not found >> -- Looking for fcntl.h >> -- Looking for fcntl.h - found >> -- Looking for inttypes.h >> -- Looking for inttypes.h - found >> -- Looking for memory.h >> -- Looking for memory.h - found >> -- Looking for stdint.h >> -- Looking for stdint.h - found >> -- Looking for stdlib.h >> -- Looking for stdlib.h - found >> -- Looking for strings.h >> -- Looking for strings.h - not found >> -- Looking for string.h >> -- Looking for string.h - found >> -- Looking for sys/stat.h >> -- Looking for sys/stat.h - found >> -- Looking for sys/time.h >> -- Looking for sys/time.h - not found >> -- Looking for sys/types.h >> -- Looking for sys/types.h - found >> -- Looking for unistd.h >> -- Looking for unistd.h - not found >> -- Looking for C++ include codecvt >> -- Looking for C++ include codecvt - found >> -- Looking for stddef.h >> -- Looking for stddef.h - found >> -- Check size of int16_t >> -- Check size of int16_t - done >> -- Check size of int32_t >> -- Check size of int32_t - done >> -- Check size of int64_t >> -- Check size of int64_t - done >> -- Check size of int8_t >> -- Check size of int8_t - done >> -- Check size of long long >> -- Check size of long long - done >> -- Check size of uint16_t >> -- Check size of uint16_t - done >> -- Check size of uint32_t >> -- Check size of uint32_t - done >> -- Check size of uint64_t >> -- Check size of uint64_t - done >> -- Check size of uint8_t >> -- Check size of uint8_t - done >> -- Check size of unsigned long long >> -- Check size of unsigned long long - done >> -- Check size of wchar_t >> -- Check size of wchar_t - done >> -- Looking for fseeko >> -- Looking for fseeko - not found >> -- Looking for mmap >> -- Looking for mmap - not found >> -- Looking for posix_fadvise >> -- Looking for posix_fadvise - not found >> -- Looking for posix_madvise >> -- Looking for posix_madvise - not found >> -- Looking for mallinfo >> -- Looking for mallinfo - not found >> -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found version >> "0.26") >> -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS MARISA_LIBRARIES) >> -- Found LibXml2: >> D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib >> >> (found version "2.9.10") >> -- Found Protobuf: >> optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib >> >> (found version "3.15.8") >> -- Found ZLIB: >> optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib >> >> (found version "1.2.11") >> ... >> >> Please show the start of your call output. I would like to see, if SDK >> and compiler were correctly found. If not, there is a script in the >> Visual Studio compiler installation to be called (See for example >> >> https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 >> ). >> >> -- >> Gruß... >> Tim >> >> >> >> _______________________________________________ >> Libosmscout-development mailing list >> Lib...@li... >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > |
From: David H. R. <dav...@gm...> - 2021-12-22 18:07:44
|
It seems that I had to get into the build dir and specify -S .. to get it done. now is working on: "cmake --build ." from inside the build dir. I'll write you back after finished. On Wed, 22 Dec 2021 at 18:55, Tim Teulings <ti...@fr...> wrote: > Hello David, > > > but don't know what does it mean. > > First the warning above: > > cmake likes to sepaeate the source directory and the build directory. > Please create a build sub directory and call cmake from with in this sub > directory (with .. as path to the root cmake file). This should make the > warning go away. > > You should also cleanup the root directory from everything that is not > part of the git content and that you did not create yourself manually. > > As you can see from the output from the latest Windoes Visual Studio > build on github > ( > https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true > (see section "Confiure build project") the start off the cmake call is > different: > > 1s > 3s > 8s > 1s > 1m 19s > 3s > 0s > 2s > 1s > 1s > 2m 15s > Run cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 > -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake > > -Wno-dev .. > -- Selecting Windows SDK version 10.0.22000.0 to target Windows 10. > -- The C compiler identification is MSVC 19.29.30138.0 > -- The CXX compiler identification is MSVC 19.29.30138.0 > -- Detecting C compiler ABI info > -- Detecting C compiler ABI info - done > -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > - skipped > -- Detecting C compile features > -- Detecting C compile features - done > -- Detecting CXX compiler ABI info > -- Detecting CXX compiler ABI info - done > -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft > Visual > Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe > - skipped > -- Detecting CXX compile features > -- Detecting CXX compile features - done > -- Looking for dlfcn.h > -- Looking for dlfcn.h - not found > -- Looking for fcntl.h > -- Looking for fcntl.h - found > -- Looking for inttypes.h > -- Looking for inttypes.h - found > -- Looking for memory.h > -- Looking for memory.h - found > -- Looking for stdint.h > -- Looking for stdint.h - found > -- Looking for stdlib.h > -- Looking for stdlib.h - found > -- Looking for strings.h > -- Looking for strings.h - not found > -- Looking for string.h > -- Looking for string.h - found > -- Looking for sys/stat.h > -- Looking for sys/stat.h - found > -- Looking for sys/time.h > -- Looking for sys/time.h - not found > -- Looking for sys/types.h > -- Looking for sys/types.h - found > -- Looking for unistd.h > -- Looking for unistd.h - not found > -- Looking for C++ include codecvt > -- Looking for C++ include codecvt - found > -- Looking for stddef.h > -- Looking for stddef.h - found > -- Check size of int16_t > -- Check size of int16_t - done > -- Check size of int32_t > -- Check size of int32_t - done > -- Check size of int64_t > -- Check size of int64_t - done > -- Check size of int8_t > -- Check size of int8_t - done > -- Check size of long long > -- Check size of long long - done > -- Check size of uint16_t > -- Check size of uint16_t - done > -- Check size of uint32_t > -- Check size of uint32_t - done > -- Check size of uint64_t > -- Check size of uint64_t - done > -- Check size of uint8_t > -- Check size of uint8_t - done > -- Check size of unsigned long long > -- Check size of unsigned long long - done > -- Check size of wchar_t > -- Check size of wchar_t - done > -- Looking for fseeko > -- Looking for fseeko - not found > -- Looking for mmap > -- Looking for mmap - not found > -- Looking for posix_fadvise > -- Looking for posix_fadvise - not found > -- Looking for posix_madvise > -- Looking for posix_madvise - not found > -- Looking for mallinfo > -- Looking for mallinfo - not found > -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found version > "0.26") > -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS MARISA_LIBRARIES) > -- Found LibXml2: > D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib > > (found version "2.9.10") > -- Found Protobuf: > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib > > (found version "3.15.8") > -- Found ZLIB: > optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib > > (found version "1.2.11") > ... > > Please show the start of your call output. I would like to see, if SDK > and compiler were correctly found. If not, there is a script in the > Visual Studio compiler installation to be called (See for example > > https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019 > ). > > -- > Gruß... > Tim > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > |
From: Tim T. <ti...@fr...> - 2021-12-22 17:55:45
|
Hello David, > but don't know what does it mean. First the warning above: cmake likes to sepaeate the source directory and the build directory. Please create a build sub directory and call cmake from with in this sub directory (with .. as path to the root cmake file). This should make the warning go away. You should also cleanup the root directory from everything that is not part of the git content and that you did not create yourself manually. As you can see from the output from the latest Windoes Visual Studio build on github (https://github.com/Framstag/libosmscout/runs/4604314355?check_suite_focus=true (see section "Confiure build project") the start off the cmake call is different: 1s 3s 8s 1s 1m 19s 3s 0s 2s 1s 1s 2m 15s Run cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_TOOLCHAIN_FILE=D:\a\libosmscout\libosmscout\vcpkg\scripts\buildsystems\vcpkg.cmake -Wno-dev .. -- Selecting Windows SDK version 10.0.22000.0 to target Windows 10. -- The C compiler identification is MSVC 19.29.30138.0 -- The CXX compiler identification is MSVC 19.29.30138.0 -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Check for working C compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped -- Detecting C compile features -- Detecting C compile features - done -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Check for working CXX compiler: C:/Program Files (x86)/Microsoft Visual Studio/2019/Enterprise/VC/Tools/MSVC/14.29.30133/bin/Hostx64/x64/cl.exe - skipped -- Detecting CXX compile features -- Detecting CXX compile features - done -- Looking for dlfcn.h -- Looking for dlfcn.h - not found -- Looking for fcntl.h -- Looking for fcntl.h - found -- Looking for inttypes.h -- Looking for inttypes.h - found -- Looking for memory.h -- Looking for memory.h - found -- Looking for stdint.h -- Looking for stdint.h - found -- Looking for stdlib.h -- Looking for stdlib.h - found -- Looking for strings.h -- Looking for strings.h - not found -- Looking for string.h -- Looking for string.h - found -- Looking for sys/stat.h -- Looking for sys/stat.h - found -- Looking for sys/time.h -- Looking for sys/time.h - not found -- Looking for sys/types.h -- Looking for sys/types.h - found -- Looking for unistd.h -- Looking for unistd.h - not found -- Looking for C++ include codecvt -- Looking for C++ include codecvt - found -- Looking for stddef.h -- Looking for stddef.h - found -- Check size of int16_t -- Check size of int16_t - done -- Check size of int32_t -- Check size of int32_t - done -- Check size of int64_t -- Check size of int64_t - done -- Check size of int8_t -- Check size of int8_t - done -- Check size of long long -- Check size of long long - done -- Check size of uint16_t -- Check size of uint16_t - done -- Check size of uint32_t -- Check size of uint32_t - done -- Check size of uint64_t -- Check size of uint64_t - done -- Check size of uint8_t -- Check size of uint8_t - done -- Check size of unsigned long long -- Check size of unsigned long long - done -- Check size of wchar_t -- Check size of wchar_t - done -- Looking for fseeko -- Looking for fseeko - not found -- Looking for mmap -- Looking for mmap - not found -- Looking for posix_fadvise -- Looking for posix_fadvise - not found -- Looking for posix_madvise -- Looking for posix_madvise - not found -- Looking for mallinfo -- Looking for mallinfo - not found -- Found PkgConfig: C:/Strawberry/perl/bin/pkg-config.bat (found version "0.26") -- Could NOT find MARISA (missing: MARISA_INCLUDE_DIRS MARISA_LIBRARIES) -- Found LibXml2: D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libxml2.lib (found version "2.9.10") -- Found Protobuf: optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/libprotobuf.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/libprotobufd.lib (found version "3.15.8") -- Found ZLIB: optimized;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/lib/zlib.lib;debug;D:/a/libosmscout/libosmscout/vcpkg/installed/x64-windows/debug/lib/zlibd.lib (found version "1.2.11") ... Please show the start of your call output. I would like to see, if SDK and compiler were correctly found. If not, there is a script in the Visual Studio compiler installation to be called (See for example https://stackoverflow.com/questions/55097222/vcvarsall-bat-for-visual-studio-2019). -- Gruß... Tim |
From: David H. R. <dav...@gm...> - 2021-12-22 17:43:41
|
I used cmd instead of powershell and: [image: image.png] but don't know what does it mean. On Wed, 22 Dec 2021 at 18:39, David Huelves Ramos <dav...@gm...> wrote: > Here is the vcpkg list > > [image: image.png] > > I'll try with cmd instead. > > On Wed, 22 Dec 2021 at 18:33, Tim Teulings <ti...@fr...> wrote: > >> Hello David, >> >> > 1) vcpkg install of all libs. OK! >> >> OK. >> >> > 2) cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF >> > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 >> > -DCMAKE_TOOLCHAIN_FILE=c:\vcpkg\scripts\buildsystems\vcpkg.cmake >> -Wno-dev >> >> > I get this: >> > >> > image.png >> >> Strange. So it looks like the libraries are still not be found. We >> should fix the error below first before this is further investigated. >> >> Please call "vcpkg list" to check if software was successfully build and >> installed (with the correct architecture). >> >> I assume that vcpkg was used correctly and cmake may have a problem, but >> it is wise to be sure :-) >> >> > and this error after that: >> > image.png >> > means: -DMAKE_SYSTEM_VERSION=10 is not known as a cmdlet name, >> function, >> > script file or exec. >> >> See >> https://cmake.org/cmake/help/latest/variable/CMAKE_SYSTEM_VERSION.html >> >> or >> >> https://gitlab.kitware.com/cmake/cmake/-/issues/16713 >> >> As far as I remember this would have influence of the Windows SDK >> versions you choose (and maybe visibility of OS header symbols). >> >> Your error looks like it is an error fro the power shell itself. I used >> DOS (cmd.exe) for my examples (I'm old, I was there before powershell >> was invented ;-)). Check if powershell needs some quoting or use a dos >> shell. >> >> Note that you now can use the *dlls and *.exe form the build for first >> experiments. >> -- >> Gruß... >> Tim >> >> >> >> _______________________________________________ >> Libosmscout-development mailing list >> Lib...@li... >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > |
From: David H. R. <dav...@gm...> - 2021-12-22 17:39:57
|
Here is the vcpkg list [image: image.png] I'll try with cmd instead. On Wed, 22 Dec 2021 at 18:33, Tim Teulings <ti...@fr...> wrote: > Hello David, > > > 1) vcpkg install of all libs. OK! > > OK. > > > 2) cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF > > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 > > -DCMAKE_TOOLCHAIN_FILE=c:\vcpkg\scripts\buildsystems\vcpkg.cmake -Wno-dev > > > I get this: > > > > image.png > > Strange. So it looks like the libraries are still not be found. We > should fix the error below first before this is further investigated. > > Please call "vcpkg list" to check if software was successfully build and > installed (with the correct architecture). > > I assume that vcpkg was used correctly and cmake may have a problem, but > it is wise to be sure :-) > > > and this error after that: > > image.png > > means: -DMAKE_SYSTEM_VERSION=10 is not known as a cmdlet name, function, > > script file or exec. > > See https://cmake.org/cmake/help/latest/variable/CMAKE_SYSTEM_VERSION.html > > or > > https://gitlab.kitware.com/cmake/cmake/-/issues/16713 > > As far as I remember this would have influence of the Windows SDK > versions you choose (and maybe visibility of OS header symbols). > > Your error looks like it is an error fro the power shell itself. I used > DOS (cmd.exe) for my examples (I'm old, I was there before powershell > was invented ;-)). Check if powershell needs some quoting or use a dos > shell. > > Note that you now can use the *dlls and *.exe form the build for first > experiments. > -- > Gruß... > Tim > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > |
From: Tim T. <ti...@fr...> - 2021-12-22 17:33:21
|
Hello David, > 1) vcpkg install of all libs. OK! OK. > 2) cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF > -DCMAKE_SYSTEM_VERSION=10.0.18362.0 > -DCMAKE_TOOLCHAIN_FILE=c:\vcpkg\scripts\buildsystems\vcpkg.cmake -Wno-dev > I get this: > > image.png Strange. So it looks like the libraries are still not be found. We should fix the error below first before this is further investigated. Please call "vcpkg list" to check if software was successfully build and installed (with the correct architecture). I assume that vcpkg was used correctly and cmake may have a problem, but it is wise to be sure :-) > and this error after that: > image.png > means: -DMAKE_SYSTEM_VERSION=10 is not known as a cmdlet name, function, > script file or exec. See https://cmake.org/cmake/help/latest/variable/CMAKE_SYSTEM_VERSION.html or https://gitlab.kitware.com/cmake/cmake/-/issues/16713 As far as I remember this would have influence of the Windows SDK versions you choose (and maybe visibility of OS header symbols). Your error looks like it is an error fro the power shell itself. I used DOS (cmd.exe) for my examples (I'm old, I was there before powershell was invented ;-)). Check if powershell needs some quoting or use a dos shell. Note that you now can use the *dlls and *.exe form the build for first experiments. -- Gruß... Tim |
From: David H. R. <dav...@gm...> - 2021-12-22 17:18:59
|
Hi again, After following the steps: 1) vcpkg install of all libs. OK! 2) cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_TOOLCHAIN_FILE=c:\vcpkg\scripts\buildsystems\vcpkg.cmake -Wno-dev I get this: [image: image.png] and this error after that: [image: image.png] means: -DMAKE_SYSTEM_VERSION=10 is not known as a cmdlet name, function, script file or exec. On Wed, 22 Dec 2021 at 09:02, David Huelves Ramos <dav...@gm...> wrote: > Hi Tim, > > I wasn't able to test the guidelines you gave me in the last email, As > soon as I get my urgency finished I'll check.. > > Thanks indeed for your assistance. > > I'll write back as soon as possible. > > Have a nice day > > On Wed, 22 Dec 2021 at 08:57, Tim Teulings <ti...@fr...> wrote: > >> Hello everybody, >> >> you can now retrieve the results of the Windows Visual Studio build as >> an GitHub Actions artifact of the build. See >> >> https://github.com/Framstag/libosmscout/actions/runs/1608207417 (at the >> end of the page) >> >> for an example URL. >> >> Artifacts should be kept 90 days for each build are then removed. >> >> I'll will improve the format of the build and archive a little bit, but >> in principle it is "done" and "usable". If something is missing, please >> tell me (and make an issue). >> >> If you have problems with the resulting binaries or their function >> please make issues (with helpful information), too. >> >> How did I test: >> I have build similar to the GitHub Action locally, generated an import >> and successfully generated a image using the DrawMapCairo demo >> application. Everything else is untested (due to lack of time). >> >> Have fun and (already ;-)) merry Christmas everybody. >> >> -- >> Gruß... >> Tim >> >> >> >> _______________________________________________ >> Libosmscout-development mailing list >> Lib...@li... >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > |
From: David H. R. <dav...@gm...> - 2021-12-22 08:02:50
|
Hi Tim, I wasn't able to test the guidelines you gave me in the last email, As soon as I get my urgency finished I'll check.. Thanks indeed for your assistance. I'll write back as soon as possible. Have a nice day On Wed, 22 Dec 2021 at 08:57, Tim Teulings <ti...@fr...> wrote: > Hello everybody, > > you can now retrieve the results of the Windows Visual Studio build as > an GitHub Actions artifact of the build. See > > https://github.com/Framstag/libosmscout/actions/runs/1608207417 (at the > end of the page) > > for an example URL. > > Artifacts should be kept 90 days for each build are then removed. > > I'll will improve the format of the build and archive a little bit, but > in principle it is "done" and "usable". If something is missing, please > tell me (and make an issue). > > If you have problems with the resulting binaries or their function > please make issues (with helpful information), too. > > How did I test: > I have build similar to the GitHub Action locally, generated an import > and successfully generated a image using the DrawMapCairo demo > application. Everything else is untested (due to lack of time). > > Have fun and (already ;-)) merry Christmas everybody. > > -- > Gruß... > Tim > > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > |
From: Tim T. <ti...@fr...> - 2021-12-22 07:57:41
|
Hello everybody, you can now retrieve the results of the Windows Visual Studio build as an GitHub Actions artifact of the build. See https://github.com/Framstag/libosmscout/actions/runs/1608207417 (at the end of the page) for an example URL. Artifacts should be kept 90 days for each build are then removed. I'll will improve the format of the build and archive a little bit, but in principle it is "done" and "usable". If something is missing, please tell me (and make an issue). If you have problems with the resulting binaries or their function please make issues (with helpful information), too. How did I test: I have build similar to the GitHub Action locally, generated an import and successfully generated a image using the DrawMapCairo demo application. Everything else is untested (due to lack of time). Have fun and (already ;-)) merry Christmas everybody. -- Gruß... Tim |
From: Tim T. <ti...@fr...> - 2021-12-21 12:51:55
|
Hello David, the Spanisch screenshot is not helpful for me ;-) I'm building for DOS terminal. These are the principal steps: call "vcpkg install" for the following packages: * zlib:x64-windows * libiconv:x64-windows * libxml2:x64-windows * protobuf:x64-windows * pixman:x64-windows * expat:x64-windows * fontconfig:x64-windows * cairo:x64-windows * harfbuzz:x64-windows * pango:x64-windows This should allow you to build the Windows and cairo backends. *This will take a while*. The code above builds 64 bit libraries. Note that while x86 binaries are supported the is a strong recommendation to build 64 bit, else the importer will likely get memory pressure problems. In your screenshot I saw a x86 build. Create a "build" directory in your checkout libosmscout git root. After that call: cmake -G "Visual Studio 16 2019" -A x64 -DOSMSCOUT_BUILD_DOC_API=OFF -DCMAKE_SYSTEM_VERSION=10.0.18362.0 -DCMAKE_TOOLCHAIN_FILE=<path to vcpkg root>\scripts\buildsystems\vcpkg.cmake -Wno-dev .. This should call cmake, which in turn must find above build packages. If not, something is already broken at this point. Please make sure that Microsoft Visual Studio is available in your dos box and also cmake can be called. Afterwards you can build the project using "cmake --build build". The builds results can be found in the build directory and its sub directories. You likely need to either copy DLLs and *.exe into one directory are must extend the PATH variable so that the DLLs can be found. That is very close to what the git hub actions build is doing. If this works, you can try to import the cmake project in Visual Studio to continue there. If you have some problems, please tell here.... There is currently one problem though. On my system the import "hangs" in step 13. I'm currently investigating this issue. I'll will continue working on some simple bundling of the build result after the import runs through and I got a simple map tile rendered via one of the demos. -- Gruß... Tim |
From: David H. R. <dav...@gm...> - 2021-12-21 11:22:18
|
I read the documentation carefully. I tried to use vcpkg installing - libiconv - libxml2 - protobuf But Still get the same error trying to import data. [image: image.png] And I have included the vcpkg line in the cmake toolchain file Following this "tutorial": [image: image.png] (Next pic is in my VS2019, it`s in spanish sorry) [image: image.png] What Am I doing wrong? On Tue, 21 Dec 2021 at 08:28, David Huelves Ramos <dav...@gm...> wrote: > Thanks indeed Tim. > > I found the library features amazing. But I can't spend a week just trying > to compile it. This is why I wrote the first message. > > Regards. > > > > On Mon, 20 Dec 2021 at 20:16, Tim <ti...@fr...> wrote: > >> Hello everbody, >> >> I updated my windows git snapshot, updated the vcpkg builds >> and rebuild everything for Visual Studio 2019 Community Edition >> (debug, dynamic linking). This is what the github action based build for >> visual studio does, too. >> >> I'm currently importing a *.pbf file. If everything works, I can try to >> enhance the github build to create a zip file as a final step with these >> build results in the next few days, which should then be available on >> the github page. The zip will just contain some *.dll and *.exe files. >> >> Since it is short before christmas I though cannot promise anything. >> >> If somebody has an idea how to quickly generate a better distribution >> using cmake instead of manually ziping things, pleas etell me. >> >> -- >> Gruß... >> Tim >> >> >> _______________________________________________ >> Libosmscout-development mailing list >> Lib...@li... >> https://lists.sourceforge.net/lists/listinfo/libosmscout-development >> > |
From: David H. R. <dav...@gm...> - 2021-12-21 07:28:53
|
Thanks indeed Tim. I found the library features amazing. But I can't spend a week just trying to compile it. This is why I wrote the first message. Regards. On Mon, 20 Dec 2021 at 20:16, Tim <ti...@fr...> wrote: > Hello everbody, > > I updated my windows git snapshot, updated the vcpkg builds > and rebuild everything for Visual Studio 2019 Community Edition > (debug, dynamic linking). This is what the github action based build for > visual studio does, too. > > I'm currently importing a *.pbf file. If everything works, I can try to > enhance the github build to create a zip file as a final step with these > build results in the next few days, which should then be available on > the github page. The zip will just contain some *.dll and *.exe files. > > Since it is short before christmas I though cannot promise anything. > > If somebody has an idea how to quickly generate a better distribution > using cmake instead of manually ziping things, pleas etell me. > > -- > Gruß... > Tim > > > _______________________________________________ > Libosmscout-development mailing list > Lib...@li... > https://lists.sourceforge.net/lists/listinfo/libosmscout-development > |
From: Tim <ti...@fr...> - 2021-12-20 19:16:41
|
Hello everbody, I updated my windows git snapshot, updated the vcpkg builds and rebuild everything for Visual Studio 2019 Community Edition (debug, dynamic linking). This is what the github action based build for visual studio does, too. I'm currently importing a *.pbf file. If everything works, I can try to enhance the github build to create a zip file as a final step with these build results in the next few days, which should then be available on the github page. The zip will just contain some *.dll and *.exe files. Since it is short before christmas I though cannot promise anything. If somebody has an idea how to quickly generate a better distribution using cmake instead of manually ziping things, pleas etell me. -- Gruß... Tim |
From: David H. R. <dav...@gm...> - 2021-12-20 17:28:04
|
On Mon, 20 Dec 2021 at 17:27, Lukáš Karas <luk...@ce...> wrote: > Hi, > > Dne pondělí 20. prosince 2021 16:59:57 CET David Huelves Ramos napsal(a): > > Hi, > > > > Thanks Lukas, for your answer. > > > > I can't test it as I can't use "Import" tool to convert/extract/Import > data > > from OSM files. None of the 2 libraries needed are added as dependencies, > > I'm totally lost modifying Cmake files (I left it 30 years ago) and I > don't > > have time to fight against it. > > > > *I hoped there were some "binary" files (libraries to link against) and > > some "include" files I could use in my code. And Some tools needed to > > generate data from OSM maps. * > > We don't expose library artifacts from CI builds, but when you build > demos, > you should have libraries already, right? > > Yes, but Debug ones.... NevertheLess What I was looking is the compiled windows version of Import (Thanks A lot) I'll try to recompile the libraries for release (just try). > Anyway, Import tool for Windows (from latest build) is here: > > > https://ci.appveyor.com/api/buildjobs/jbufgh6h848kltc9/artifacts/libosmscout-importer-Windows-x86_64.zip > > Or you may download map database from my server https://osmscout.karry.cz/ > but every database consists from 24 files, it is not convenient to > download > them manually. > > > Thanks again for your help but I think, I'll search further to see if I > can > > find precompiled binaries of any other library as I only need to render > and > > draw over it using local osm files. > > You are welcome. Good luck with searching, it depends what is your > usecase, > what stack you are using... > > Regards, Lukas > > > On Mon, 20 Dec 2021 at 16:49, Lukáš Karas <luk...@ce...> > wrote: > > > Hi David. > > > > > > Welcome on mailing list. > > > > > > Dne pondělí 20. prosince 2021 11:23:53 CET David Huelves Ramos > napsal(a): > > > > Hello, > > > > > > > > I'm new to libosmscout. I have just downloaded from Github and > generate > > > > from VS2019. > > > > > > > > I get lot of executable files but I don't really know where to start > > > > looking. > > > > > > You may start with demos in "Demos" directory. There you can find > various > > > simple demos that shows library usage. > > > > > > > I've seen there is an example called DrawCGI but don't know where the > > > > > > code > > > > > > > is neither how to > > > > run it. > > > > > > Source for this demo is here: > > > > > > > https://github.com/Framstag/libosmscout/blob/master/Demos/src/DrawMapGDI.c > > > pp> > > > > What I'm looking is for an example (code) that shows the basics on > > > > offline OSM maps for windows that I can debug or at least see how > > > > could I use the library. > > > > > > Just execute that DrawCGI demo from command line, it will tell you what > > > arguments it expect (I have no Windows, so I cannot test it right now). > > > > > > But you will definitely will need some map database. You may download > it > > > using > > > OSMScout2 demo, or import it by Import tool from OpenStreetMap extract. > > > > > > Regards, Lukas > > > > > > > Thanks in advance. > > > > > > > > Regards. |
From: Lukáš K. <luk...@ce...> - 2021-12-20 16:27:32
|
Hi, Dne pondělí 20. prosince 2021 16:59:57 CET David Huelves Ramos napsal(a): > Hi, > > Thanks Lukas, for your answer. > > I can't test it as I can't use "Import" tool to convert/extract/Import data > from OSM files. None of the 2 libraries needed are added as dependencies, > I'm totally lost modifying Cmake files (I left it 30 years ago) and I don't > have time to fight against it. > > *I hoped there were some "binary" files (libraries to link against) and > some "include" files I could use in my code. And Some tools needed to > generate data from OSM maps. * We don't expose library artifacts from CI builds, but when you build demos, you should have libraries already, right? Anyway, Import tool for Windows (from latest build) is here: https://ci.appveyor.com/api/buildjobs/jbufgh6h848kltc9/artifacts/libosmscout-importer-Windows-x86_64.zip Or you may download map database from my server https://osmscout.karry.cz/ but every database consists from 24 files, it is not convenient to download them manually. > Thanks again for your help but I think, I'll search further to see if I can > find precompiled binaries of any other library as I only need to render and > draw over it using local osm files. You are welcome. Good luck with searching, it depends what is your usecase, what stack you are using... Regards, Lukas > On Mon, 20 Dec 2021 at 16:49, Lukáš Karas <luk...@ce...> wrote: > > Hi David. > > > > Welcome on mailing list. > > > > Dne pondělí 20. prosince 2021 11:23:53 CET David Huelves Ramos napsal(a): > > > Hello, > > > > > > I'm new to libosmscout. I have just downloaded from Github and generate > > > from VS2019. > > > > > > I get lot of executable files but I don't really know where to start > > > looking. > > > > You may start with demos in "Demos" directory. There you can find various > > simple demos that shows library usage. > > > > > I've seen there is an example called DrawCGI but don't know where the > > > > code > > > > > is neither how to > > > run it. > > > > Source for this demo is here: > > > > https://github.com/Framstag/libosmscout/blob/master/Demos/src/DrawMapGDI.c > > pp> > > > What I'm looking is for an example (code) that shows the basics on > > > offline OSM maps for windows that I can debug or at least see how > > > could I use the library. > > > > Just execute that DrawCGI demo from command line, it will tell you what > > arguments it expect (I have no Windows, so I cannot test it right now). > > > > But you will definitely will need some map database. You may download it > > using > > OSMScout2 demo, or import it by Import tool from OpenStreetMap extract. > > > > Regards, Lukas > > > > > Thanks in advance. > > > > > > Regards. |
From: David H. R. <dav...@gm...> - 2021-12-20 16:00:36
|
Hi, Thanks Lukas, for your answer. I can't test it as I can't use "Import" tool to convert/extract/Import data from OSM files. None of the 2 libraries needed are added as dependencies, I'm totally lost modifying Cmake files (I left it 30 years ago) and I don't have time to fight against it. *I hoped there were some "binary" files (libraries to link against) and some "include" files I could use in my code. And Some tools needed to generate data from OSM maps. * Thanks again for your help but I think, I'll search further to see if I can find precompiled binaries of any other library as I only need to render and draw over it using local osm files. On Mon, 20 Dec 2021 at 16:49, Lukáš Karas <luk...@ce...> wrote: > Hi David. > > Welcome on mailing list. > > Dne pondělí 20. prosince 2021 11:23:53 CET David Huelves Ramos napsal(a): > > Hello, > > > > I'm new to libosmscout. I have just downloaded from Github and generate > > from VS2019. > > > > I get lot of executable files but I don't really know where to start > > looking. > > You may start with demos in "Demos" directory. There you can find various > simple demos that shows library usage. > > > > > I've seen there is an example called DrawCGI but don't know where the > code > > is neither how to > > run it. > > Source for this demo is here: > > https://github.com/Framstag/libosmscout/blob/master/Demos/src/DrawMapGDI.cpp > > > > > What I'm looking is for an example (code) that shows the basics on > > offline OSM maps for windows that I can debug or at least see how > > could I use the library. > > Just execute that DrawCGI demo from command line, it will tell you what > arguments it expect (I have no Windows, so I cannot test it right now). > > But you will definitely will need some map database. You may download it > using > OSMScout2 demo, or import it by Import tool from OpenStreetMap extract. > > Regards, Lukas > > > > > Thanks in advance. > > > > Regards. |
From: Lukáš K. <luk...@ce...> - 2021-12-20 15:50:06
|
Hi David. Welcome on mailing list. Dne pondělí 20. prosince 2021 11:23:53 CET David Huelves Ramos napsal(a): > Hello, > > I'm new to libosmscout. I have just downloaded from Github and generate > from VS2019. > > I get lot of executable files but I don't really know where to start > looking. You may start with demos in "Demos" directory. There you can find various simple demos that shows library usage. > > I've seen there is an example called DrawCGI but don't know where the code > is neither how to > run it. Source for this demo is here: https://github.com/Framstag/libosmscout/blob/master/Demos/src/DrawMapGDI.cpp > > What I'm looking is for an example (code) that shows the basics on > offline OSM maps for windows that I can debug or at least see how > could I use the library. Just execute that DrawCGI demo from command line, it will tell you what arguments it expect (I have no Windows, so I cannot test it right now). But you will definitely will need some map database. You may download it using OSMScout2 demo, or import it by Import tool from OpenStreetMap extract. Regards, Lukas > > Thanks in advance. > > Regards. |
From: David H. R. <dav...@gm...> - 2021-12-20 10:24:11
|
Hello, I'm new to libosmscout. I have just downloaded from Github and generate from VS2019. I get lot of executable files but I don't really know where to start looking. I've seen there is an example called DrawCGI but don't know where the code is neither how to run it. What I'm looking is for an example (code) that shows the basics on offline OSM maps for windows that I can debug or at least see how could I use the library. Thanks in advance. Regards. |
From: Lukáš K. <luk...@ce...> - 2021-12-19 21:52:08
|
Forwarding Asim's response to mailing list... --- Thanks a lot for your help, Lukas! The route is now showing on top of the map. However, I am not very familiar with Qt, so it will take a while for me to understand the Qt/QML component to display the current location. I believe showing the current position is very much possible using the backend renderer (e.g Cairo) by using GeoToPixel to draw markers at the current location. But, is there a way to add the current location in the map data itself, i.e, similar to how we add the route information to the map data? Also, I will leave this snippet for displaying the route, in case anyone else stumbles upon this thread. // This is a snippet for adding the route info to map data which builds upon the Routing.cpp demo. // This allows renderers to display the calculated route on the map. // data is an instance of osmscout::MapData class. osmscout::TypeInfoRef route_type_info = typeConfig->GetTypeInfo("_route"); if ( !route_type_info ){ std::cerr << "_route is not registered!" << std::endl; return; } osmscout::RouteWayResult routing_way = router->TransformRouteDataToWay( result.GetRoute() ); if ( !routing_way.Success() ){ std::cerr << "Unable to convert route data to way!" << std::endl; } else { std::cout << "Converted route data to way!" << std::endl; auto way_ref = routing_way.GetWay(); way_ref->SetType(route_type_info); data.poiWays.push_back(way_ref); } Regards, Asim Maharjan On Mon, Dec 13, 2021 at 9:23 PM Lukáš Karas <luk...@ce...> wrote: > Hi Asim. > > There is Qt / QML component that can show current position and calculated > route. Usage can be found in OSMScout2 demo app. But it is interactive > application with UI. It is far more complicated than these Draw* demos. > > We don't have demo with Cairo backend for this usecase. I made fast look > to > your demo and you are on the right direction. You don't have to register > "_route" type for your own, it is kind of special and it is registered by > default, see > > > https://github.com/Framstag/libosmscout/blob/master/libosmscout/src/ osmscout/ > TypeConfig.cpp#L865 > <https://github.com/Framstag/libosmscout/blob/master/libosmscout/src/ osmscout/TypeConfig.cpp#L865> > > Just lookup it by name: > > osmscout::TypeInfoRef type=typeConfig->GetTypeInfo("_route"); > if (!type){ > osmscout::log.Warn() << "Type \"_route\" is not registered for way"; > return false; > } > > Regards, Lukas > > Dne pondělí 13. prosince 2021 15:09:31 CET Asim Maharjan napsal(a): > > Greetings everyone, > > > > I am very new to libosmscout and would like to know how to display > > calculated routes and current location marker (using latitude and > longitude > > coordinates). > > > > The libosmscout tutorial page (here > > <http://libosmscout.sourceforge.net/tutorials/renderonmap/>) says that > it > > is possible to show the current route and current position on top of the > > map. However, I can't seem to find any example code to achieve this. > > > > There are previous discussions present on this topic, here > > <https://sourceforge.net/p/libosmscout/mailman/message/30205963/>. The > > discussion however seems to be old and there have been some API changes > > now. So, have the steps for displaying routes changed in any way? > > > > This <https://www.toptal.com/developers/hastebin/tefiqitece.php> is the > > code I have currently. It is the DrawMapCairo demo with the routing code > > copied from the Routing demo. The relevant code for adding the route to > the > > MapData class is present in the calculate_route function: > > > > osmscout::TypeInfoRef route_type_info = > > std::make_shared<osmscout::TypeInfo>("_route"); > > route_type_info->SetInternal().CanBeWay(true); > > > > typeConfig->RegisterType( route_type_info ); > > > > osmscout::RouteWayResult routing_way = router->TransformRouteDataToWay( > > result.GetRoute() ); > > > > if ( !routing_way.Success() ){ > > std::cerr << "Unable to convert route data to way!" << std::endl; > > } else { > > std::cout << "Converted route data to way!" << std::endl; > > auto way_ref = routing_way.GetWay(); > > way_ref->SetType(route_type_info); > > data.poiWays.push_back(way_ref); > > } > > > > It would be very helpful if you could provide some helpful pointers or > > example code to display the calculated routes. > > > > Thank you very much! > > > > Regards, > > Asim Maharjan ----------------------------------------- |
From: Lukáš K. <luk...@ce...> - 2021-12-19 21:51:53
|
Hi Asim Dne úterý 14. prosince 2021 17:41:48 CET jste napsal(a): > Thanks a lot for your help, Lukas! > The route is now showing on top of the map. Great to read that! > However, I am not very familiar with Qt, so it will take a while for me to > understand the Qt/QML component to display the current location. > I believe showing the current position is very much possible using the > backend renderer (e.g Cairo) by using GeoToPixel to draw markers at the > current location. Yes, it is the simplest solution. It will also allow you to render map just once when you want to update position marker "live", lets say every second. You can create copy of rendered image and then put marker to desired position (until location is in visible area). > But, is there a way to add the current location in the map data itself, > i.e, similar to how we add the route information to the map data? It is also possible. Just define some symbol in stylesheet (standard.oss), or use some predefined, for example "marker": SYMBOL marker CIRCLE 0,0 0.8 { AREA {color: #ff0000; } } then define style for new node type, for example "_current_position": [MAG world-] { [TYPE _current_position] { NODE.ICON { symbol: marker; priority: 0; } } } register "_current_position" type in C++ code, when you open database: osmscout::TypeInfoRef typeInfo = std::make_shared<osmscout::TypeInfo>("_current_position"); typeInfo->SetInternal().CanBeNode(true); typeConfig->RegisterType(typeInfo); then just create node instance and add it data object as poiNode before rendering: osmscout::TypeInfoRef type=typeConfig.GetTypeInfo("_current_position"); if (type) { osmscout::NodeRef n = std::make_shared<osmscout::Node>(); n->SetType(type); n->SetCoords( currentLocation ); // TODO data.poiNodes.push_back(n); } Regards, Lukas > Also, I will leave this snippet for displaying the route, in case anyone > else stumbles upon this thread. > > // This is a snippet for adding the route info to map data which builds > upon the Routing.cpp demo. > // This allows renderers to display the calculated route on the map. > // data is an instance of osmscout::MapData class. > osmscout::TypeInfoRef route_type_info = typeConfig->GetTypeInfo("_route"); > if ( !route_type_info ){ > std::cerr << "_route is not registered!" << std::endl; > return; > } > > osmscout::RouteWayResult routing_way = router->TransformRouteDataToWay( > result.GetRoute() ); > if ( !routing_way.Success() ){ > std::cerr << "Unable to convert route data to way!" << std::endl; > } else { > std::cout << "Converted route data to way!" << std::endl; > auto way_ref = routing_way.GetWay(); > way_ref->SetType(route_type_info); > data.poiWays.push_back(way_ref); > } > Regards, > Asim Maharjan > > On Mon, Dec 13, 2021 at 9:23 PM Lukáš Karas <luk...@ce...> wrote: > > Hi Asim. > > > > There is Qt / QML component that can show current position and calculated > > route. Usage can be found in OSMScout2 demo app. But it is interactive > > application with UI. It is far more complicated than these Draw* demos. > > > > We don't have demo with Cairo backend for this usecase. I made fast look > > to > > your demo and you are on the right direction. You don't have to register > > "_route" type for your own, it is kind of special and it is registered by > > default, see > > > > > > https://github.com/Framstag/libosmscout/blob/master/libosmscout/src/osmsco > > ut/ TypeConfig.cpp#L865 > > <https://github.com/Framstag/libosmscout/blob/master/libosmscout/src/osmsc > > out/TypeConfig.cpp#L865>> > > Just lookup it by name: > > osmscout::TypeInfoRef type=typeConfig->GetTypeInfo("_route"); > > if (!type){ > > > > osmscout::log.Warn() << "Type \"_route\" is not registered for way"; > > return false; > > > > } > > > > Regards, Lukas > > > > Dne pondělí 13. prosince 2021 15:09:31 CET Asim Maharjan napsal(a): > > > Greetings everyone, > > > > > > I am very new to libosmscout and would like to know how to display > > > calculated routes and current location marker (using latitude and > > > > longitude > > > > > coordinates). > > > > > > The libosmscout tutorial page (here > > > <http://libosmscout.sourceforge.net/tutorials/renderonmap/>) says that > > > > it > > > > > is possible to show the current route and current position on top of the > > > map. However, I can't seem to find any example code to achieve this. > > > > > > There are previous discussions present on this topic, here > > > <https://sourceforge.net/p/libosmscout/mailman/message/30205963/>. The > > > discussion however seems to be old and there have been some API changes > > > now. So, have the steps for displaying routes changed in any way? > > > > > > This <https://www.toptal.com/developers/hastebin/tefiqitece.php> is the > > > code I have currently. It is the DrawMapCairo demo with the routing code > > > copied from the Routing demo. The relevant code for adding the route to > > > > the > > > > > MapData class is present in the calculate_route function: > > > osmscout::TypeInfoRef route_type_info = > > > > > > std::make_shared<osmscout::TypeInfo>("_route"); > > > > > > route_type_info->SetInternal().CanBeWay(true); > > > > > > typeConfig->RegisterType( route_type_info ); > > > > > > osmscout::RouteWayResult routing_way = > > > router->TransformRouteDataToWay( > > > > > > result.GetRoute() ); > > > > > > if ( !routing_way.Success() ){ > > > > > > std::cerr << "Unable to convert route data to way!" << std::endl; > > > > > > } else { > > > > > > std::cout << "Converted route data to way!" << std::endl; > > > auto way_ref = routing_way.GetWay(); > > > way_ref->SetType(route_type_info); > > > data.poiWays.push_back(way_ref); > > > > > > } > > > > > > It would be very helpful if you could provide some helpful pointers or > > > example code to display the calculated routes. > > > > > > Thank you very much! > > > > > > Regards, > > > Asim Maharjan |
From: Lukáš K. <luk...@ce...> - 2021-12-13 16:02:11
|
Hi Asim. There is Qt / QML component that can show current position and calculated route. Usage can be found in OSMScout2 demo app. But it is interactive application with UI. It is far more complicated than these Draw* demos. We don't have demo with Cairo backend for this usecase. I made fast look to your demo and you are on the right direction. You don't have to register "_route" type for your own, it is kind of special and it is registered by default, see https://github.com/Framstag/libosmscout/blob/master/libosmscout/src/osmscout/ TypeConfig.cpp#L865 Just lookup it by name: osmscout::TypeInfoRef type=typeConfig->GetTypeInfo("_route"); if (!type){ osmscout::log.Warn() << "Type \"_route\" is not registered for way"; return false; } Regards, Lukas Dne pondělí 13. prosince 2021 15:09:31 CET Asim Maharjan napsal(a): > Greetings everyone, > > I am very new to libosmscout and would like to know how to display > calculated routes and current location marker (using latitude and longitude > coordinates). > > The libosmscout tutorial page (here > <http://libosmscout.sourceforge.net/tutorials/renderonmap/>) says that it > is possible to show the current route and current position on top of the > map. However, I can't seem to find any example code to achieve this. > > There are previous discussions present on this topic, here > <https://sourceforge.net/p/libosmscout/mailman/message/30205963/>. The > discussion however seems to be old and there have been some API changes > now. So, have the steps for displaying routes changed in any way? > > This <https://www.toptal.com/developers/hastebin/tefiqitece.php> is the > code I have currently. It is the DrawMapCairo demo with the routing code > copied from the Routing demo. The relevant code for adding the route to the > MapData class is present in the calculate_route function: > > osmscout::TypeInfoRef route_type_info = > std::make_shared<osmscout::TypeInfo>("_route"); > route_type_info->SetInternal().CanBeWay(true); > > typeConfig->RegisterType( route_type_info ); > > osmscout::RouteWayResult routing_way = router->TransformRouteDataToWay( > result.GetRoute() ); > > if ( !routing_way.Success() ){ > std::cerr << "Unable to convert route data to way!" << std::endl; > } else { > std::cout << "Converted route data to way!" << std::endl; > auto way_ref = routing_way.GetWay(); > way_ref->SetType(route_type_info); > data.poiWays.push_back(way_ref); > } > > It would be very helpful if you could provide some helpful pointers or > example code to display the calculated routes. > > Thank you very much! > > Regards, > Asim Maharjan |
From: Asim M. <mah...@gm...> - 2021-12-13 14:09:50
|
Greetings everyone, I am very new to libosmscout and would like to know how to display calculated routes and current location marker (using latitude and longitude coordinates). The libosmscout tutorial page (here <http://libosmscout.sourceforge.net/tutorials/renderonmap/>) says that it is possible to show the current route and current position on top of the map. However, I can't seem to find any example code to achieve this. There are previous discussions present on this topic, here <https://sourceforge.net/p/libosmscout/mailman/message/30205963/>. The discussion however seems to be old and there have been some API changes now. So, have the steps for displaying routes changed in any way? This <https://www.toptal.com/developers/hastebin/tefiqitece.php> is the code I have currently. It is the DrawMapCairo demo with the routing code copied from the Routing demo. The relevant code for adding the route to the MapData class is present in the calculate_route function: osmscout::TypeInfoRef route_type_info = std::make_shared<osmscout::TypeInfo>("_route"); route_type_info->SetInternal().CanBeWay(true); typeConfig->RegisterType( route_type_info ); osmscout::RouteWayResult routing_way = router->TransformRouteDataToWay( result.GetRoute() ); if ( !routing_way.Success() ){ std::cerr << "Unable to convert route data to way!" << std::endl; } else { std::cout << "Converted route data to way!" << std::endl; auto way_ref = routing_way.GetWay(); way_ref->SetType(route_type_info); data.poiWays.push_back(way_ref); } It would be very helpful if you could provide some helpful pointers or example code to display the calculated routes. Thank you very much! Regards, Asim Maharjan |