rules_haskell icon indicating copy to clipboard operation
rules_haskell copied to clipboard

Document how to deal with internal libraries with stack snapshot

Open facundominguez opened this issue 2 years ago • 1 comments

The latest versions of attoparsec use an internal library, and when using the newest stackage snapshots, one needs to do extra configuration in the stack_snapshot rule.

    components =
        { "attoparsec": [
                "lib",
                "lib:attoparsec-internal",
            ],
        },
    components_dependencies =
        {
            "attoparsec": """{"lib:attoparsec": ["lib:attoparsec-internal"]}""",
        },

Ideally, this extra bit of configuration would be discussed in the top-level docstring for stack_snapshot and it would be mentioned in the user guide.

Probably the documentation could also link at why this extra bit of configuration is necessary: https://github.com/commercialhaskell/stack/issues/5275

facundominguez avatar Jun 20 '22 15:06 facundominguez

In case it helps anyone searching, similarly for pandoc 3 the following is required:

components = {                                        
    "pandoc": [                                       
        "lib",                                        
        "lib:xml-light",                              
    ],                                                
},                                                    
components_dependencies = {                           
    "pandoc": """{"lib:pandoc": ["lib:xml-light"]}""",
},

jonathanlking avatar Mar 07 '23 12:03 jonathanlking