sub fetches package, using fetch(3), and adds it to the SUBDIRS variable used by the rules file. package should be the name of a package containing a makefile that includes the rules file.
Adding a package to the SUBDIRS variable means that it will be built and installed as a part (subsystem) of the product. It is important that make_rules(3) also is used, since it includes the rules file that contains the makefile magic that recurses all SUBDIRS.