Skip to content

Commit 88b3269

Browse files
author
Mitsutoshi Aoe
committed
Add installation instructions
1 parent 4cd10b0 commit 88b3269

File tree

1 file changed

+64
-0
lines changed

1 file changed

+64
-0
lines changed

README.md

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,3 +3,67 @@
33
[![Hackage-Deps](https://img.shields.io/hackage-deps/v/threadscope.svg)](http://packdeps.haskellers.com/feed?needle=threadscope)
44
[![Build Status](https://travis-ci.org/haskell/ThreadScope.svg?branch=master)](https://travis-ci.org/haskell/ThreadScope)
55
[![Build status](https://ci.appveyor.com/api/projects/status/y6kd8pyh2f3qok4f?svg=true)](https://ci.appveyor.com/project/Mikolaj/threadscope)
6+
7+
## Installation
8+
9+
### Linux
10+
11+
GTK+2 is required to be installed. On Ubuntu-like systems:
12+
13+
```sh
14+
sudo apt install libgtk2.0-dev
15+
```
16+
17+
Then you can build threadscope using cabal:
18+
```sh
19+
cabal new-build
20+
```
21+
22+
Or using stack:
23+
```sh
24+
stack setup
25+
stack install
26+
```
27+
28+
### macOS
29+
30+
GTK+ and gtk-mac-integration are required.
31+
32+
```sh
33+
brew install gtk+ gtk-mac-integration
34+
```
35+
36+
Then you can build threadscope using cabal:
37+
```sh
38+
cabal new-build --constraint="gtk +have-quartz-gtk"
39+
```
40+
41+
Or using stack:
42+
```sh
43+
stack setup
44+
stack install --flag gtk:have-quartz-gtk
45+
```
46+
47+
### Windows
48+
49+
stack is the recommended tool to build threadscope on Windows.
50+
51+
CAVEAT: Currently gtk2 needs to be installed twice: one for stack's MSYS2 environment and another for local MSYS2 environment.
52+
53+
In command prompt:
54+
```sh
55+
stack setup
56+
stack exec -- pacman --needed -Sy bash pacman pacman-mirrors msys2-runtime msys2-runtime-devel
57+
stack exec -- pacman -Syu
58+
stack exec -- pacman -Syuu
59+
stack exec -- pacman -S base-devel mingw-w64-x86_64-pkg-config mingw-w64-x86_64-toolchain mingw-w64-x86_64-gtk2
60+
stack install
61+
```
62+
63+
Then in MSYS2 MINGW64 shell:
64+
```sh
65+
pacman -S $MINGW_PACKAGE_PREFIX-gtk2
66+
echo 'export PATH=$APPDATA/local/bin:$PATH' >> .profile
67+
source .profile
68+
threadscope
69+
```

0 commit comments

Comments
 (0)