README.rst 2.94 KB
Newer Older
Keshav Kini's avatar
Keshav Kini committed
1
2
Gentoo Haskell project
**********************
3

4
|pkgcheck-badge| |repoman-badge|
5

6
.. |pkgcheck-badge| image:: https://github.com/gentoo-haskell/gentoo-haskell/workflows/pkgcheck/badge.svg
7
8
    :target: https://github.com/gentoo-haskell/gentoo-haskell/actions?query=workflow%3Apkgcheck

9
.. |repoman-badge| image:: https://github.com/gentoo-haskell/gentoo-haskell/workflows/repoman/badge.svg
10
11
    :target: https://github.com/gentoo-haskell/gentoo-haskell/actions?query=workflow%3Arepoman

12
13
14
Quickest start
==============

15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
First, let's enable the Gentoo Haskell overlay. We can either use the
eselect-repository method::

    # Install eselect-repository if you don't already have it
    emerge app-eselect/eselect-repository
    # Fetch and output the list of overlays
    eselect repository list
    eselect repository enable haskell

or we can use the layman method::
  
    # Add important USE flags for layman to your package.use directory:
    echo "app-portage/layman sync-plugin-portage git" >> /etc/portage/package.use/layman
    # Install layman if you don't already have it
    emerge app-portage/layman
    # Rebuild layman's repos.conf file:
    layman-updater -R
    # Add the Gentoo Haskell overlay:
33
    layman -a haskell
34
35
36

Finally, we need to unmask the overlay (this does not apply if your system
is already running on the ~testing branch)::
Jack Todaro's avatar
Jack Todaro committed
37
    # Unmask ~testing versions for your arch:
38
    echo "*/*::haskell ~$(portageq envvar ARCH)" >> /etc/portage/package.accept_keywords
39

40
41
42
43
44
And here is the trick to speed up metadata resolution a bit.
If you happen to use ``eix-sync`` for rsyncs you might
like the following ``/etc/eix-sync.conf``::

    *
45
    @egencache --jobs="$(($(nproc) + 1))" --repo=haskell --update --update-use-local-desc
46
47
48
49
50

It basically means:

- sync overlays in layman list before the main tree sync

51
- generate metadata for haskell repo after main
Alexander Berntsen's avatar
Alexander Berntsen committed
52
  tree sync is done, using N+1 cores
53

54
55
Developer's corner
==================
56

57
58
Have a nice haskell-related ebuild to share with community?
Look at our `Developer's README`_!
59

60
.. _Developer's README: http://github.com/gentoo-haskell/gentoo-haskell/blob/master/projects/doc/README.rst
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78

Loner's corner
==============

Alternatively if you really don't want to share any ebuilds (want to keep
outdated package versions, highly experimental things, publically unavailable
stuff, other reasons) that's also fine.

You can keep such ebuilds in your local overlay.

Here is a complete example of creating minimal overlay with a
single haskell ebuild from hackage::

    # create overlay and populate it (gentoo-generic):
    $ mkdir my-ovl
    $ cd    my-ovl
    $ mkdir metadata
    $ echo 'masters = gentoo' > metadata/layout.conf
79
80
81
    # register an overlay in /etc/portage/repos.conf:
    $ echo '[my-ovl]' >> /etc/portage/repos.conf
    $ echo "location = $(pwd)" >> /etc/portage/repos.conf
82
83
84
85
86
87
88
89
    
    # haskell-specific stuff
    $ hackport -p . update
    # DONE!
    
    # adding an example ebuild
    $ hackport merge hichi
    $ emerge -av1 hichi