blob: f80de492206b7b632649e43679560c6c7b357841 [file] [log] [blame] [view]
Andrew Gerrand5bc444d2014-12-10 11:35:11 +11001# Go on OpenBSD
2
Constantine A. Murenin1beb25b2015-02-25 20:26:18 +00003Go is available within the OpenBSD ports tree collection since OpenBSD 5.2. It is marked as i386- and amd64- only. See [`ports/lang/go`](http://ports.su/lang/go) for details.
Constantine A. Mureninc2964ab2015-02-25 20:04:31 +00004
Dimitri Sokolyuk0f43a302017-10-10 09:17:44 +02005| **OpenBSD release** | **Go in ports** |
Constantine A. Mureninc2964ab2015-02-25 20:04:31 +00006|:--------------------|:--------------------|
Dimitri Sokolyukb4b74912019-11-19 03:44:52 +01007| 6.6 (Oct 17, 2019) | go-1.13.1 |
Dimitri Sokolyukad755092019-08-07 00:10:32 +02008| 6.5 (Apr 4, 2019) | go-1.12.1 |
9| 6.4 (Oct 18, 2018) | go-1.11 |
10| 6.3 (Apr 2, 2018) | go-1.10 |
Dimitri Sokolyuk0f43a302017-10-10 09:17:44 +020011| 6.2 (Oct 9, 2017) | go-1.9 |
Dimitri Sokolyuk09a63d12017-04-22 13:03:37 +020012| 6.1 (Apr 11, 2017) | go-1.8 |
Dimitri Sokolyukec097922016-09-10 15:31:41 +020013| 6.0 (Sep 1, 2016) | go-1.6.3 |
Dimitri Sokolyukf0ac4272016-04-24 00:44:03 +020014| 5.9 (Mar 29, 2016) | go-1.5.4 |
Dimitri Sokolyuk6502da82015-10-19 17:15:00 +020015| 5.8 (Oct 18, 2015) | go-1.4.2 |
Jack Peirce67c88152015-05-07 20:20:37 -060016| 5.7 (May 1, 2015) | go-1.4.1 |
Constantine A. Murenin1beb25b2015-02-25 20:26:18 +000017| 5.6 (Nov 1, 2014) | go-1.3p0 |
Constantine A. Mureninc2964ab2015-02-25 20:04:31 +000018
Mikio Hara82de2872016-09-29 14:41:13 +090019## Building from source
Constantine A. Mureninc2964ab2015-02-25 20:04:31 +000020
Mikio Harac53c0cd2016-10-20 16:15:03 +090021| **Kernel version** | **Architectures** | **Initial support version** | **Final support version** |
22|:-------------------|:------------------|:----------------------------|:--------------------------|
mikioh96f68ee2018-08-01 11:16:10 +090023| 6.4 | amd64, arm, 386 | Go 1.11 | |
24| 6.2 through 6.3 | amd64, arm, 386 | Go 1.9 | |
mikioh8fc45622019-01-24 08:47:46 +090025| 6.1 | amd64, arm, 386 | Go 1.8 | Go 1.10.8 |
26| 6.0 | amd64, 386 | Go 1.4.1 _*_ | Go 1.10.8 |
27| 6.0 | arm | Go 1.5 | Go 1.10.8 |
Mikio Hara47264402018-02-08 08:58:37 +090028| 5.9 | amd64, 386 | Go 1.4.1 _*_ | Go 1.8.7 |
29| 5.9 | arm | Go 1.5 | Go 1.8.7 |
Mikio Hara21fdcde2017-05-24 21:35:56 +090030| 5.6 through 5.8 | amd64, 386 | Go 1.4.1 _*_ | Go 1.7.6 |
31| 5.5 | amd64, 386 | Go 1.3 _*_ | Go 1.7.6 |
Mikio Harac53c0cd2016-10-20 16:15:03 +090032| 5.0 through 5.4 | amd64, 386 | Go 1 | Go 1.2.2 |
Mikio Hara69c9dc42017-03-23 12:35:02 +090033
Mikio Haraddebc2c2016-09-29 16:31:41 +090034_*_ Go 1.5 or above is recommended.
Andrew Gerrand5bc444d2014-12-10 11:35:11 +110035
Erik Williamson1c94c542017-09-28 20:20:43 -070036## Longterm support
37
Erik Williamson2221b052017-09-28 20:26:55 -070038Go aims to support the two most recent OpenBSD releases, because OpenBSD officially supports only the two most recent releases, and makes a best-effort attempt to maintain ABI support in consecutive releases.
Erik Williamson1c94c542017-09-28 20:20:43 -070039
Mikio Hara82de2872016-09-29 14:41:13 +090040## ulimits (` /etc/login.conf `)
Andrew Gerrand5bc444d2014-12-10 11:35:11 +110041
Michael McConville8ccc3172016-01-13 23:39:29 -050042Edit `/etc/login.conf` so that the staff class has the proper
Andrew Gerrand5bc444d2014-12-10 11:35:11 +110043settings. The following is a working example of the staff class:
44```
45staff:\
46 :datasize-cur=infinity:\
47 :datasize-max=infinity:\
48 :datasize=infinity:\
49 :openfiles-cur=4096:\
50 :maxproc-max=512:\
51 :maxproc-cur=512:\
52 :ignorenologin:\
53 :requirehome@:\
54 :tc=default:
55```
56
Michael McConvilleeee069b2016-01-13 23:36:43 -050057If the database file `/etc/login.conf.db` exists, you need to rebuild it with:
Andrew Gerrand5bc444d2014-12-10 11:35:11 +110058```
59# cap_mkdb /etc/login.conf
60```
61
Michael McConville1abb1222016-01-13 23:41:10 -050062Ensure that the user you intend to build Go with is in the `staff` login class:
Andrew Gerrand5bc444d2014-12-10 11:35:11 +110063```
Michael McConville1abb1222016-01-13 23:41:10 -050064# usermod -L staff your_username_here
Michael McConville9d08e0a2016-01-13 23:17:38 -050065```