INSTALL.md

Thu, 05 Sep 2019 06:54:06 +0200

author
David Demelier <markand@malikania.fr>
date
Thu, 05 Sep 2019 06:54:06 +0200
branch
release-2.1
changeset 37
69a71a9a0ebf
parent 35
b50f9c2d3c64
child 41
dff275f0783d
permissions
-rw-r--r--

misc: added signature for changeset 44c1c7726652

0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
1 NSnake INSTALL
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
2 ==============
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
3
32
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
4 To build nsnake, you need a C compiler and ncurses.
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
5
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
6 Note for Windows
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
7 ----------------
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
8
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
9 NSnake works on Windows but it does not have a native curses library, however
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
10 you can use [pdcurses][] which is the implementation known to work with NSnake.
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
11
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
12 Build
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
13 -----
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
14
32
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
15 Go to the source directory and type the following commands:
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
16
1
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
17 make
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
18 make install
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
19
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
20 Build configuration
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
21 -------------------
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
22
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
23 The following options may be used to configure the build.
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
24
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
25 - `GID`: change the gid to chown (default: games),
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
26 - `UID`: change the uid to chown (default: games),
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
27 - `PREFIX`: root directory for installation
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
28 - `BINDIR`: change to the installation of executable (default: PREFIX/bin),
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
29 - `MANDIR`: change to the manual page location (default: PREFIX/share/man),
35
b50f9c2d3c64 misc: update before 2.1.0
David Demelier <markand@malikania.fr>
parents: 32
diff changeset
30 - `VARDIR`: change the score file database directory (default: PREFIX/var).
1
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
31
32
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
32 Also, edit config.mk file to adjust NSnake to your system otherwise fallback
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
33 implementations will be bundled in.
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
34
1
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
35 Scores file
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
36 -----------
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
37
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
38 NSnake uses a scores file in order to share all users scores on the same
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
39 machine. In order to work, the binary `nsnake` but have setgid file attribute
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
40 and its database directory with the appropriate permissions. This is
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
41 automatically done as `make install` step.
0
85dcf82636b2 Initial import
David Demelier <markand@malikania.fr>
parents:
diff changeset
42
28
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
43 The directory for saving the scores is writable by this group to make sure the
0c49fb9c5420 misc: switch back to Makefile
David Demelier <markand@malikania.fr>
parents: 26
diff changeset
44 executable can write it from any user.
1
0e0ee35dae66 Add post install script to chown binary and directory
David Demelier <markand@malikania.fr>
parents: 0
diff changeset
45
32
87f25ca1954b misc: add a config.mk file
David Demelier <markand@malikania.fr>
parents: 28
diff changeset
46 [pdcurses]: https://pdcurses.org

mercurial