-
Notifications
You must be signed in to change notification settings - Fork 9
/
INSTALL
103 lines (71 loc) · 3.66 KB
/
INSTALL
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
chip8 emulator: Installation instructions
Copyright (C) 2015 Dani Rodríguez
In order to compile this software, download the sources from the project
web site and extract them into a software folder. Source code packages
can be downloaded from the releases directory. These packages already
contains a `configure` script generated by the GNU Autotools System.
As an alternative, you may download the sources by cloning the Git
repository for this project. However, these sources cannot be directly
compiled, as the `configure` script has to be manually created. See below
for more information.
Compiling the project.
To compile this software, cd to the folder where you have extracted
your source code and run the following commands using your terminal
./configure
make
Alternatively, you may prefer to build this package on a separate
directory from the directory where your sources are located. In that
case you must invoke `configure` script as
$PATH_TO_SOURCES/configure
make
Where $PATH_TO_SOURCES is the destination where the package sources
are located. For instance, if you are compiling the project from a
subfolder you may invoke `configure` as `../configure`.
Installing the project
After successfully running `make`, run `make install`. This will
copy generated output by `make` into the preferred destination. By
default they will be installed to /usr/local. You can change this
directory by invoking `configure` as
./configure --prefix=$FOLDER
where $FOLDER is the folder where you want to install the program
to. Please note that binaries are not directly installed to $FOLDER
but to $FOLDER/bin. For instance, to install the package into your
home directory, run
./configure --prefix=$HOME
The emulator will be installed at ~/bin/chip8.
Uninstalling the project
If you haven't still delete files generated by ./configure script,
you can uninstall this software by running
make uninstall
If you have already deleted the output files generated by ./configure
or even the entire sources distribution, you must invoke again
`./configure` using the same prefix than the one you provided when
installing the software.
Compiling on Windows
This project can be build on Windows provided you have a compatible
system. MinGW has been tested and it works. You must install into your
MSYS system SDL2 if you want the code to compile. Cygwin hasn't been
tested although it is expected to work.
To successfully compile the emulator on Windows you must provide
some linker flags when compiling it. You must either execute the
following commands:
LDFLAGS='-lmingw32 -lSDL2main -lSDL2' ./configure
make
Or the following
./configure
LDFLAGS='-lmingw32 -lSDL2main -lSDL2' make
Generating compile script from bootstrap
If you download a source code distribution from the releases page
you may get a tarball with a `configure` script that generates a
valid Makefile to compile the project using make.
If you instead clone or pull the Git repository, you won't get
that `configure` script since it's generated by GNU Autotools.
You must run the bootstrap script first:
./bootstrap
./configure
make
Please note that `bootstrap` requires GNU Autotools installed to work.
You must have GNU Autoconf and GNU Autoheader installed and working.
The bootstrap script will execute `autoreconf`, which automatically
executes every program from the GNU Autotools suite that is required
to generate the configuration scripts.