File tree Expand file tree Collapse file tree
Cabal/src/Distribution/Simple/Setup Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -151,7 +151,7 @@ buildOptions progDb showOrParseArgs =
151151 , option
152152 []
153153 [" semaphore" ]
154- " Use the specified semaphore so GHC can compile components in parallel"
154+ " Use the specified semaphore identifier so GHC can compile components in parallel"
155155 buildUseSemaphore
156156 (\ v flags -> flags{buildUseSemaphore = v})
157157 (reqArg' " SEMAPHORE" Flag flagToList)
Original file line number Diff line number Diff line change 1+ synopsis: Better document Cabal's ` --semaphore=SEMAPHORE ` option in light of ` semaphore-compat-2.0.0 `
2+ packages: Cabal
3+ prs: #12022
4+ significance:
5+
6+ description: {
7+
8+ - Cabal's ` --semaphore=SEMAPHORE ` option is better documented in the user's guide and in ` --help ` .
9+
10+ }
Original file line number Diff line number Diff line change @@ -1089,13 +1089,22 @@ This command takes the following options:
10891089
10901090 :since: 3.12.0.0
10911091
1092+ This option causes Cabal to control parallelism by using the specified
1093+ semaphore.
1094+
10921095 GHC 9.8.1 and later can act as a jobserver client, which enables two or more
10931096 GHC processes running at once to share system resources with each other,
1094- communicating via a specified system semaphore. The system semaphore is
1095- identified by a name (a string).
1097+ communicating via a semaphore.
10961098
1097- This option causes Cabal to control parallelism by using the specified
1098- system semaphore.
1099+ The expected use is that the system controlling the build (e.g.
1100+ ``cabal-install ``, ``stack ``, ``nix `` or ``buck2 ``) (a jobserver) creates or
1101+ obtains a semaphore using the ``semaphore-compat `` library. It then passes
1102+ the semaphore to jobserver clients in order to control the amount of
1103+ parallelism. This is done by passing the corresponding semaphore identifier
1104+ to Cabal via the ``--semaphore `` option.
1105+
1106+ For more information, see
1107+ `semaphore-compat <https://hackage.haskell.org/package/semaphore-compat >`_.
10991108
11001109.. _setup-haddock :
11011110
You can’t perform that action at this time.
0 commit comments