Changes between Version 22 and Version 23 of Repositories


Ignore:
Timestamp:
Sep 1, 2011 12:21:11 PM (3 years ago)
Author:
simonpj
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • Repositories

    v22 v23  
    2626 * '''"`extra`"''': extra packages you might want to include in a build (the `parallel` package, for example), but aren't necessary to get a working GHC. 
    2727 
    28 == Repository locations == 
     28== Repository and mirrors == 
    2929 
    3030Many of the libraries and tools in a GHC tree are actually maintained by someone else. They therefore have a separate upstream repository, from which we need to pull. That repository may be either a darcs or a git repository; in the darcs case, we also need to convert to a git repository for use in a GHC tree. However, if the darcs repository is on another server, then we first need to mirror it for the conversion program to use. This diagram shows how changes migrate from one repo to another: 
     
    3232[[Image(repos.png)]] 
    3333 
    34 This means that when making changes needed in GHC to one of these libraries, we first need to put the changes in the upstream repository. For example, to make a change to Cabal: 
     34This means that when making changes needed in GHC to one of these libraries, we first need to put the changes in the upstream repository. Note that a git hook prevents you from pushing patches to the ghc repos until they are already in the git mirror repos, so that we cannot forget to send changes upstream. 
    3535 
    36  * First push the change as a darcs patch to the upstream Cabal repository, http://code.haskell.org/Cabal/ 
    37  * The patch will be mirrored and converted to git by the mirror script, in the repo http://darcs.haskell.org/git-mirrors/Cabal/.git/ 
    38  * You then need to pull from http://darcs.haskell.org/git-mirrors/Cabal/.git/ into `libraries/Cabal` in a regular GHC tree, validate, and push to the GHC Cabal repo, http://darcs.haskell.org/packages/Cabal.git/ 
     36== When the master repo is in Git == 
    3937 
    40 Note that a git hook prevents you from pushing patches to the ghc repos until they are already in the git mirror repos, so that we cannot forget to send changes upstream. 
     38If the master (upstream) repo is in Git (eg `containers`), you can use the following workflow: 
     39 1. Push the change to the upstream repo `//github.com/haskell/containers.git` 
     40 2. Push the change to the validated GHC repo for `containers`, namely [http://darcs.haskell.org/packages/containers.git] 
    4141 
     42In other words, you don't need to interact with the git mirror on `darcs.haskell.org`. It is ''only'' there so that in step (2), the push script can check that the patch you are pushing is in the mirror, thereby ensuring that we always lag the master repo.  (For some reason this is hard to do directly on the master.) 
     43 
     44So step 2 may fail until the mirror has been updated, which may take overnight.  I believe there is a way to kick the mirror into action earlier, but I don't know what it is. (Ian?) 
     45 
     46== When the master repo is in Darcs ==  
     47 
     48Things are a bit more complicated when the master repo is in Darcs.  For example, to make a change to Cabal: 
     49 
     50 1. First push the change as a darcs patch to the upstream Cabal repository, http://code.haskell.org/Cabal/ 
     51 2. The patch will be mirrored and converted to git by the mirror script, in the repo http://darcs.haskell.org/git-mirrors/Cabal/.git/ 
     52 3. You then need to pull from http://darcs.haskell.org/git-mirrors/Cabal/.git/ into `libraries/Cabal` in a regular GHC tree, validate, and push to the GHC Cabal repo, http://darcs.haskell.org/packages/Cabal.git/ 
     53 
     54== Repository locations ==  
    4255{{{ 
    4356#!html