rxp_write_dag function

Generate a DAG from a list of derivations