1# Chapter 19: pgrx-schema/src, forty lines 2 3One file, and it is short enough to read in a minute. `run` takes its four 4arguments, reads the `.so`, finds the section whose name pgrx recognises as 5a schema section (`is_schema_section_name`), and refuses with "no pgrx 6schema section" if there is none. It parses the control file, decodes the 7entities (`decode_entities`), and builds the script with `PgrxSql::build`. 8 9The one decision in it is borrowed from cargo-pgrx: a control file that 10names `module_pathname`, as this one does, gets `MODULE_PATHNAME` in the 11script, and one that does not gets a versioned library path. 12 13> **Try it.** Read [main.rs](main.rs) top to bottom. Errors go to stderr as 14> `pgrx-schema: …` with exit code 1, which is how buck shows a failed 15> `:ext` build. 16 17## For the people who maintain it 18 19| File | What | 20| --- | --- | 21| [main.rs](main.rs) | The whole tool. | 22 23← Previous: [Chapter 18, pgrx-schema/](../) · Up: [pgrx-schema](../) · Next: [Chapter 20, cargo-gen/](../../cargo-gen/) →