summaryrefslogtreecommitdiff
path: root/Docs/QUICK-START
blob: 9ff3fb5e9e38e031467194eface2da3fab77af2b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
--------------------------------------------------------------------------------
  Quick Build Steps for NetSurf                               24 February 2015
--------------------------------------------------------------------------------

  This document provides steps for building NetSurf.


  Grab a temporary env.sh
--------------------------

      $ wget http://git.netsurf-browser.org/netsurf.git/plain/Docs/env.sh
      $ source env.sh


  Install any packages you need
-------------------------------

  Installs all packages required to build NetSurf and the NetSurf project
  libraries.

      $ ns-package-install

  If your package manager is not supported, you will have to install third
  party packages manually.


  Get the NetSurf project source code from Git
----------------------------------------------

      $ ns-clone


  Build and install our project libraries
-----------------------------------------

   Updates NetSurf project library sources to latest, builds and installs them.

      $ ns-pull-install


  Switch to new NetSurf workspace
---------------------------------

      $ rm env.sh
      $ cd ~/dev-netsurf/workspace
      $ source env.sh


  Build and run NetSurf
-----------------------

      $ cd netsurf

  To build the native front end (the GTK front end on Linux, BSDs, etc) you
  could do:

      $ make
      $ ./nsgtk

  To build the framebuffer front end, you could do:

      $ make TARGET=framebuffer
      $ ./nsfb


  Cross Compiling
=================

  If you are cross compiling, you can follow the above steps, but when sourcing
  env.sh, you should set TARGET_ABI to the appropriate triplet for your cross
  compiler.  For example, to cross compile for RISC OS:

      $ TARGET_ABI=arm-unknown-riscos source env.sh

  After that, the commands such as `ns-package-install` and `ns-pull-install`
  will do what is appropriate for the platform you are building for.

  To do the final build of NetSurf, pass the appropriate TARGET to make.  For
  example, to cross compile for RISC OS:

      $ make TARGET=riscos

  Finally, you can package up your build to transfer to the system you are
  developing for.  For example, to produce a package for RISC OS:

      $ make TARGET=riscos package

  Getting a cross compiler set up
---------------------------------

  We maintain cross compilation environments and an SDK for a number of
  platforms.  These may be found in our toolchains repository.

      $ git clone git://git.netsurf-browser.org/toolchains

  Pre-built versions of the toolchains for Debian systems are often available
  via our automated build and test infrastructure:

      http://ci.netsurf-browser.org/builds/toolchains/


  Not working?
==============

  If the above steps are inapplicable, or don't work, you can build manually.
  Follow the instructions in the BUILDING-* documents in the Docs/ directory
  the NetSurf browser source tree.