diff options
author | Joseph Herlant <aerostitch@users.noreply.github.com> | 2019-10-29 09:56:27 -0700 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-10-29 09:56:27 -0700 |
commit | 91c085e7f9e0e31eaedd9926b3682d980587333c (patch) | |
tree | 34ffdd98c4cf915011fea175bf65c3351abb70bb /docs | |
parent | aefa85db918cd8026814ad12802fc319dea18699 (diff) | |
download | navit-91c085e7f9e0e31eaedd9926b3682d980587333c.tar.gz |
update:doc: Fix windows doc and cleanup sphinx warnings (#927)
Diffstat (limited to 'docs')
-rw-r--r-- | docs/development/android_development.rst | 14 | ||||
-rw-r--r-- | docs/development/wince_development.rst | 4 | ||||
-rw-r--r-- | docs/development/windows_development.rst | 178 |
3 files changed, 103 insertions, 93 deletions
diff --git a/docs/development/android_development.rst b/docs/development/android_development.rst index 783a29e91..323a0d877 100644 --- a/docs/development/android_development.rst +++ b/docs/development/android_development.rst @@ -22,7 +22,7 @@ For Navit For Android ~~~~~~~~~~~ - * Download the Android `SDK <http://dl.google.com/android/android-sdk_r18-linux.tgz>` and `NDK <http://dl.google.com/android/ndk/android-ndk-r8-linux-x86.tar.bz2>` + * Download the Android `SDK <http://dl.google.com/android/android-sdk_r18-linux.tgz>`_ and `NDK <http://dl.google.com/android/ndk/android-ndk-r8-linux-x86.tar.bz2>`_ * Unzip the SDK and NDK to a directory of your choice. The following instructions assume that the SDK and NDK have been unzipped to `~/src`. * Ensure that the following paths are on your PATH environment variable: `path-to-sdk/tools` @@ -88,7 +88,7 @@ With cmake on Windows * install CMake 2.8 if you haven't already, add folder with exe to PATH * install MinGW or use MinGW included in the git windows folder (e.g. C:\msysgit\mingw\ ), add folder with exe to PATH - * install saxon .NET version from <http://sourceforge.net/projects/saxon/files/Saxon-HE/9.3/SaxonHE9-3-0-4N-setup.exe/download>, + * install saxon .NET version from http://sourceforge.net/projects/saxon/files/Saxon-HE/9.3/SaxonHE9-3-0-4N-setup.exe/download, * rename `transform.exe` to `saxon.exe`, add folder with exe to PATH * create a build dir (i.e. `mkdir android-build`) * run from build dir ( replace `$SOURCE_PATH`): @@ -135,19 +135,19 @@ Change to the Navit source dir and run `./gradlew build`. So far, two issues have been observed with the build: + * Bitmap resources are missing from the APK. A workaround is described `here <https://github.com/navit-gps/navit/pull/553#issuecomment-406881461>`_ integration of these steps into gradle is being worked on. * Building `vehicle/gpsd` and `map/garmin` fails on Android. As a workaround, edit `CMakeLists.txt` `, inserting the following two lines in the `if(ANDROID)` block (around line 710): -.. code-block:: +.. code-block:: cmake set_with_reason(vehicle/gpsd "Android detected" FALSE) set_with_reason(map/garmin "Android detected" FALSE) - * Bitmap resources are missing from the APK. A workaround is described `here <https://github.com/navit-gps/navit/pull/553#issuecomment-406881461>` — integration of these steps into gradle is being worked on. Testing an alternative build ============================ If you want to try an alternative build (e.g. Jan's builds with alternative routing) you can do it by : - * enable unsigned apk installation ( `example build <http://www.tomsguide.com/faq/id-2326514/download-install-android-apps-unidentified-developer.html>` ) - * installing an alternative apk (e.g. `an APK from CircleCI <https://circle-artifacts.com/gh/jandegr/navit/292/artifacts/0/tmp/circle-artifacts.MZk9Slb/navit-96b3160a2e51dffb54e3aa74c17ce3683c52828e-debug.apk>`) - * you will probably need an alternative map to match the application requirements (such as `this one <https://circle-artifacts.com/gh/jandegr/navit/265/artifacts/0/tmp/circle-artifacts.WJkkT78/BNLFR.bin>`) + * enable unsigned apk installation ( `example build <http://www.tomsguide.com/faq/id-2326514/download-install-android-apps-unidentified-developer.html>`_ ) + * installing an alternative apk (e.g. `an APK from CircleCI <https://circle-artifacts.com/gh/jandegr/navit/292/artifacts/0/tmp/circle-artifacts.MZk9Slb/navit-96b3160a2e51dffb54e3aa74c17ce3683c52828e-debug.apk>`_) + * you will probably need an alternative map to match the application requirements (such as `this one <https://circle-artifacts.com/gh/jandegr/navit/265/artifacts/0/tmp/circle-artifacts.WJkkT78/BNLFR.bin>`_) diff --git a/docs/development/wince_development.rst b/docs/development/wince_development.rst index 423139460..7f15672ed 100644 --- a/docs/development/wince_development.rst +++ b/docs/development/wince_development.rst @@ -204,7 +204,7 @@ libpng libtiff ^^^^^^^ -.. code-block:: +:: libtool: link: CURRENT `' must be a nonnegative integer @@ -222,7 +222,7 @@ libtiff glib ^^^^ -.. code-block:: +:: gatomic.c:570: Error: no such instruction: `swp %eax,%eax,[%esi]' diff --git a/docs/development/windows_development.rst b/docs/development/windows_development.rst index 1c5248605..6aa695f82 100644 --- a/docs/development/windows_development.rst +++ b/docs/development/windows_development.rst @@ -5,7 +5,7 @@ Windows Development Compiling using CMake ===================== -At the moment, compiling with [[CMake]] seems to be the only way to create a runnable binary in Windows. +At the moment, compiling with CMake seems to be the only way to create a runnable binary in Windows. Compiling / debugging using CodeBlocks & mingw compiler @@ -32,14 +32,14 @@ Install the packages mentioned above. After everything has been installed you ca .. warning:: - Not up to date! Directory projs\CodeBlocks was deleted in 2009 + Not up to date! Directory projs\CodeBlocks was deleted in 2009 Compiling --------- .. warning:: - Not up to date! Directory projs\CodeBlocks was deleted in 2009 + Not up to date! Directory projs\CodeBlocks was deleted in 2009 To compile: @@ -73,8 +73,9 @@ Download cygwin Download the cygwin setup.exe from http://cygwin.com/setup.exe .. note:: - I have been unable to build with cygwin according to these instructions. I suggest you only try it if you are knowledgable - and can improve the instructions. --[[User:Nop|Nop]] 13:01, 7 November 2010 (UTC) + + I have been unable to build with cygwin according to these instructions. I suggest you only try it if you are knowledgable + and can improve the instructions. --[[User:Nop|Nop]] 13:01, 7 November 2010 (UTC) Dependencies ------------ @@ -110,13 +111,13 @@ Edit configure.in and add the following to CFLAGS at line 10: .. code-block:: bash - -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include + -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include It should look like this : .. code-block:: bash - CFLAGS="$CFLAGS -Wall -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -D_GNU_SOURCE -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include" + CFLAGS="$CFLAGS -Wall -Wcast-align -Wmissing-declarations -Wmissing-prototypes -Wstrict-prototypes -Wpointer-arith -Wreturn-type -D_GNU_SOURCE -I/usr/include/glib-2.0 -I/usr/lib/glib-2.0/include" Now run `autogen.sh && ./configure` @@ -153,7 +154,7 @@ Configuration GPS .. note:: - If this works at all, it's only when running under cygwin. See above for the proper Win32 configuration. --[[User:Nop|Nop]] 13:04, 7 November 2010 (UTC) + If this works at all, it's only when running under cygwin. See above for the proper Win32 configuration. --[[User:Nop|Nop]] 13:04, 7 November 2010 (UTC) If you have a gps cable device which spits out NMEA data, you can configure it like under unix. Beware of the following enumeration: * ComPort1==ttyS0 @@ -164,7 +165,7 @@ Example: .. code-block:: xml - <vehicle name="GPSOnCom3" profilename="car" enabled="yes" active="1" source="file:/dev/ttyS2" baudrate="38400" color="#0000ff"/> + <vehicle name="GPSOnCom3" profilename="car" enabled="yes" active="1" source="file:/dev/ttyS2" baudrate="38400" color="#0000ff"/> Running under Cygwin -------------------- @@ -189,42 +190,38 @@ Downloads --------- In order to compile the win32 version of Navit, you need the following software development tools - * GTK+ toolkit for win32 from `SourceForgeDownload: Glade/GTK+ <http://sourceforge.net/project/showfiles.php?group_id=98754>` (select gtk+-win32-devel) - * MinGW from `SourceForgeDownload: MinGW <http://sourceforge.net/project/showfiles.php?group_id=2435>`_ (select Automated MinGW installer) - * MSYS from `SourceForgeDownload: MSYS Base System <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=2496>` - * msysCORE from `SourceForgeDownload: MSYS Base System <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=24963>` - * diffutils from `SourceForgeDownload: MSYS Base System <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=24963>` - * autoconf from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>` - * autogen from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>` - * automake from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>` - * gettext from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>` - * libtool from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>` - * libiconv from `SourceForgeDownload: MSYS Supplementary Tools <http://sourceforge.net/downloads/mingw/MinGW/libiconv>` - -Probably the easiest way to obtain and install all the MSYS packages is to follow the instructions `here <http://www.mingw.org/wiki/msys>` + * GTK+ toolkit for win32 from `Glade/GTK+ <http://sourceforge.net/project/showfiles.php?group_id=98754>`_ (select gtk+-win32-devel) + * MinGW from `MinGW <http://sourceforge.net/project/showfiles.php?group_id=2435>`_ (select Automated MinGW installer) + * MSYS from `MSYS Base System <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=2496>`_ + * msysCORE from `MSYSCore Base System <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=24963>`_ + * diffutils from `diffutils <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=24963>`_ + * autoconf, autogen, automake, gettext and libtool from `MSYS Supplementary Tools <http://sourceforge.net/project/showfiles.php?group_id=2435&package_id=67879>`_ + * libiconv from `MinGW's libiconv <http://sourceforge.net/downloads/mingw/MinGW/libiconv>`_ + +Probably the easiest way to obtain and install all the MSYS packages is to follow the instructions `here <http://www.mingw.org/wiki/msys>`_ For speech support, one option is to use the "cmdline" speech type (refer to [[Configuration]]) and a utility such as a Windows port of `Say <http://krolik.net/wsvn/wsvn/public/Say%2B%2B/>`_ TroubleShooting =============== -.. code-block:: +:: - /bin/m4: unrecognized option '--gnu' + /bin/m4: unrecognized option '--gnu' Wrong version of m4, use 1.4.13 -.. code-block:: +:: - Can't locate object method "path" via package "Request (perhaps you forgot to load "Request"?) + Can't locate object method "path" via package "Request (perhaps you forgot to load "Request"?) Wrong version of Autoconf, make sure the latest version is installed, plus the wrapper (version 1.7). Also delete autom4te.cache. -.. code-block:: +:: - command PKG_MODULE_EXISTS not recognized + command PKG_MODULE_EXISTS not recognized For some reason the necessary file "pkg.m4" containing various macros is missing. Find it and put it in ./m4 @@ -236,33 +233,39 @@ This is a quick walk-thru on compiling a win32 exe using Ubuntu as development m Set up Ubuntu to build Linux version ------------------------------------ -First, setup compiling in linux ubuntu explained in https://navit.readthedocs.io/en/trunk/development/linux_development.html +First, setup compiling in linux ubuntu explained in :doc:`/development/linux_development` Here is a quick walk-thru: Get all the dependencies for Ubuntu in one command: .. code-block:: bash - sudo apt-get install cmake zlib1g-dev libpng12-dev libgtk2.0-dev librsvg2-bin \ + sudo apt-get install cmake zlib1g-dev libpng12-dev libgtk2.0-dev librsvg2-bin \ g++ gpsd gpsd-clients libgps-dev libdbus-glib-1-dev freeglut3-dev libxft-dev \ libglib2.0-dev libfreeimage-dev gettext -get the latest SVN-source. -First, cd into root: `cd ~` +get the latest source from git. First, cd into root: `cd ~` Now, let's grab the code from SVN. This assumes that you have subversion installed. This will download the latest SVN source and put in in folder "navit-source". You can use any location you want for the source, just to keep it simple we place it right in the root. -`svn co svn://svn.code.sf.net/p/navit/code/trunk/navit/ navit-source` + +.. code-block:: bash + + git clone git@github.com:navit-gps/navit.git navit-source Create a directory to put the build in and cd into it: .. code-block:: bash - mkdir navit-build - cd navit-build + mkdir navit-build + cd navit-build -Start compiling and build navit: `cmake ~/navit-source && make` +Start compiling and build navit: + +.. code-block:: bash + + cmake ~/navit-source && make At the end of the process navit is built into navit-build/. You can start navit to see if all worked well: @@ -277,38 +280,42 @@ Building the win32 exe Now that we have set up the basic building environment we can build a win32 exe using the next walk-thru. -Install ming32 and the dependencies: `sudo apt-get install mingw32 libsaxonb-java librsvg2-bin mingw32-binutils mingw32-runtime default-jdk` +Install ming32 and the dependencies: + +.. code-block:: bash + + sudo apt-get install mingw32 libsaxonb-java librsvg2-bin mingw32-binutils mingw32-runtime default-jdk now cd into the source: .. code-block:: bash - cd ~ - cd navit-source + cd ~ + cd navit-source We are going to place the build directory within the source directory. First, make the build directory and cd into it: .. code-block:: bash - mkdir build - cd build + mkdir build + cd build From within the build directory start compiling and building: .. code-block:: bash - cmake -DCMAKE_TOOLCHAIN_FILE=../Toolchain/mingw32.cmake ../ + cmake -DCMAKE_TOOLCHAIN_FILE=../Toolchain/mingw32.cmake ../ And then make the actual build: .. code-block:: bash - make -j4 + make -j4 The -j4 part is used to define the amount of processors the process can use. -So if you have a dual-core pc use -j2 -If -j4 fails, try -j2 and if that fails try "make" alone. +So if you have a dual-core pc use `-j2` +If `-j4` fails, try `-j2` and if that fails try `make` alone. Known "bugs" ------------ @@ -319,7 +326,11 @@ Cut and paste (or move) the "locale" folder to the navit folder. This should be investigated anf fixed so the folder is in the correct place after a build. So move `navit-source/build/locale/` to `navit-source/build/navit/locale` -You can run `mv navit-source/build/locale/ navit-source/build/navit/` +You can run + +.. code-block:: bash + + mv navit-source/build/locale/ navit-source/build/navit/ The country-flags images in the "town" search are not displayed. This could be due to a conversion error during build, has to be investigated and solved but doesn't inflict with the use of navit. @@ -331,10 +342,9 @@ You can delete those without any problem. Windows Mobile/Windows CE ========================= -[[WinCE_development]] may have details that are relevant for compilation on WindowsCE / Windows Mobile. +:doc:`/development/wince_development` may have details that are relevant for compilation on WindowsCE / Windows Mobile. -You can download now -[http://download.navit-project.org/navit/wince/svn/ cab or zip file for Windows Mobile and WindowsCE]! +You can download now `cab or zip file for Windows Mobile and WindowsCE <http://download.navit-project.org/navit/wince/svn/>`_ ! Highest number is the newest version of NavIt. Download it and save on your Storage Card. Install it. @@ -347,13 +357,13 @@ This is a manual for self compiling (navit.exe) You need to have a Linux (like Ubuntu). If you didn´t have Linux, start your Linux on Live-CD. -Compiling navit for wince using http://cegcc.sourceforge.net/. +Compiling navit for wince using `<http://cegcc.sourceforge.net/>`_. Download latest cegcc release and install it. In November 2009 versions compiled using arm-cegcc-gcc (both revision 1214 and release 0.59.1) had problems (threw exception_datatype_misalignment and caused access violations).<br /> -Using the variant arm-mingw32ce of CeGCC 0.59.1 it was possible to build a working executable which can be debugged (see [[WinCE development]]). +Using the variant arm-mingw32ce of CeGCC 0.59.1 it was possible to build a working executable which can be debugged (see :doc:`/development/wince_development`). -Source [http://www.archlinux.de/?page=PackageDetails;package=4837 cegcc-arm and mingw] (TODO dead link) +Source `cegcc-arm and mingw <http://www.archlinux.de/?page=PackageDetails;package=4837>`_ (TODO dead link) Current installs in /opt/cegcc. Setup a cross-compile environment: @@ -362,16 +372,16 @@ Example setcegccenv.sh: .. code-block:: bash - #! /bin/bash - export PATH=$PATH:/opt/cegcc/bin/ - export CEGCC_PATH=/opt/cegcc - export WINCE_PATH=/opt/wince - export PATH=$CEGCC_PATH/bin:$PATH - export CPPFLAGS="-I$WINCE_PATH/include" - export LDFLAGS="-L$WINCE_PATH/lib -L$CEGCC_PATH/lib" - export LD_LIBRARY_PATH="$WINCE_PATH/bin" - export PKG_CONFIG_PATH="$WINCE_PATH/lib/pkgconfig" - export PKG_CONFIG_LIBDIR="$WINCE_PATH/lib/pkgconfig" + #! /bin/bash + export PATH=$PATH:/opt/cegcc/bin/ + export CEGCC_PATH=/opt/cegcc + export WINCE_PATH=/opt/wince + export PATH=$CEGCC_PATH/bin:$PATH + export CPPFLAGS="-I$WINCE_PATH/include" + export LDFLAGS="-L$WINCE_PATH/lib -L$CEGCC_PATH/lib" + export LD_LIBRARY_PATH="$WINCE_PATH/bin" + export PKG_CONFIG_PATH="$WINCE_PATH/lib/pkgconfig" + export PKG_CONFIG_LIBDIR="$WINCE_PATH/lib/pkgconfig" For installation, compiling and configuring please see manual for NavIt on Linux. @@ -380,7 +390,7 @@ Then autogen.sh and configure navit. Example configure for wince: .. code-block:: bash - ./configure \ + ./configure \ RANLIB=arm-cegcc-ranlib \ CXX=arm-cegcc-g++ \ CC=arm-cegcc-gcc \ @@ -416,7 +426,7 @@ If example did not run, do this: .. code-block:: bash - ./configure \ + ./configure \ RANLIB=arm-mingw32ce-ranlib \ CXX=arm-mingw32ce-g++ \ CC=arm-mingw32ce-gcc \ @@ -462,26 +472,26 @@ For installation you need packages librapi, liprapi2, pyrapi2, libsync. Package synce-0.9.0-1 contains librapi and libsync. You do not need to install it again! -Sources: [http://sourceforge.net/project/showfiles.php?group_id=30550 Sync] If link is crashed, use this: [http://rpmfind.net/linux/rpm2html/search.php?query=librapi.so.2 Sync Link2] -libsync: [http://sourceforge.net/project/mirror_picker.php?height=350&width=300&group_id=30550&use_mirror=puzzle&filesize=&filename=libsynce-0.12.tar.gz&abmode= libsync] -pyrapi2: [http://rpmfind.net/linux/rpm2html/search.php?query=pyrapi2.so pyrapi2] -librapi2 [http://repository.slacky.eu/slackware-12.0/libraries/synce-librapi/0.11.0/src/ librapi2] +Sources: `Sync <http://sourceforge.net/project/showfiles.php?group_id=30550>`_ If link is crashed, use this: `Sync Link2 <http://rpmfind.net/linux/rpm2html/search.php?query=librapi.so.2>`_ +libsync: `libsync <http://sourceforge.net/project/mirror_picker.php?height=350&width=300&group_id=30550&use_mirror=puzzle&filesize=&filename=libsynce-0.12.tar.gz&abmode=>`_ +pyrapi2: `pyrapi2 <http://rpmfind.net/linux/rpm2html/search.php?query=pyrapi2.so>`_ +librapi2 `librapi2 <http://repository.slacky.eu/slackware-12.0/libraries/synce-librapi/0.11.0/src/>`_ Once you have navit.exe ready, copy `/opt/cegcc/arm-cegcc/lib/device/*.dll` on your device. For Debian use: -.. code-block:: +.. code-block:: bash - synce-pcp /opt/cegcc/arm-cegcc/lib/device/cegcc.dll ":/windows/cegcc.dll" - synce-pcp /opt/cegcc/arm-cegcc/lib/device/cegccthrd.dll ":/windows/cegccthrd.dll" + synce-pcp /opt/cegcc/arm-cegcc/lib/device/cegcc.dll ":/windows/cegcc.dll" + synce-pcp /opt/cegcc/arm-cegcc/lib/device/cegccthrd.dll ":/windows/cegccthrd.dll" All other Linux/Unix systems use: -.. code-block:: +.. code-block:: bash - pcp /opt/cegcc/arm-cegcc/lib/device/cegcc.dll ":/windows/cegcc.dll" - pcp /opt/cegcc/arm-cegcc/lib/device/cegccthrd.dll ":/windows/cegccthrd.dll" + pcp /opt/cegcc/arm-cegcc/lib/device/cegcc.dll ":/windows/cegcc.dll" + pcp /opt/cegcc/arm-cegcc/lib/device/cegccthrd.dll ":/windows/cegccthrd.dll" Synchronisation with a grahic surface, if connection to device failed: @@ -502,15 +512,15 @@ Install navit.exe. Debian: -.. code-block:: +.. code-block:: bash - synce-pcp navit.exe ":/Storage Card/navit.exe" + synce-pcp navit.exe ":/Storage Card/navit.exe" All other: -.. code-block:: +.. code-block:: bash - pcp navit.exe ":/Storage Card/navit.exe" + pcp navit.exe ":/Storage Card/navit.exe" Prepare a navit.xml.wince @@ -521,17 +531,17 @@ Fix the paths to your maps "/Storage Card/binfilemap.bin" Debian: -.. code-block:: +.. code-block:: bash - synce-pcp binfilemap.bin ":/Storage Card/binfilemap.bin" - synce-pcp navit.xml.wince ":/Storage Card/navit.xml" + synce-pcp binfilemap.bin ":/Storage Card/binfilemap.bin" + synce-pcp navit.xml.wince ":/Storage Card/navit.xml" All other: -.. code-block:: +.. code-block:: bash - pcp binfilemap.bin ":/Storage Card/binfilemap.bin" - pcp navit.xml.wince ":/Storage Card/navit.xml" + pcp binfilemap.bin ":/Storage Card/binfilemap.bin" + pcp navit.xml.wince ":/Storage Card/navit.xml" For a start best use the samplemap. |