If "primary_src" or "current_src" on the command line specifies a *.RC file, PBShell will invoke the resource compiler instead of the PB compiler.
If "primary_src" specifies a BASIC source file, and "current_src" specifies a *.RC file, and if the BASIC file contains a #RESOURCE metacommand to specify the target *.PBR file, PBShell will use the #RESOURCE specification as the output path and name of the *.RES file when compiling the resource script with RC.EXE. PBRES.EXE will then be executed in the target directory to produce the *.PBR file. This allows you to keep the *.RC file in a different directory to the output resource file, and even for it to have a different name if you want. In the overwhelming majority of cases, the input directory will be the same as the output directory, and this facility is only available when using the built-in resource linker of PB, but the facility is there if it is needed.
If you use the #RESOURCE metacommand to include resources in your programs, as assumed above, you can skip the rest of this section. But if you don't like to use PBRES.EXE, read on.
If you pass the resource file for compilation along with a primary source file which includes a #RESOURCE metacommand, PBShell will try to produce a PBR file from the RC resource script file (producing an error if it was unsuccessful) and delete the intermediate RES file.
But if the #RESOURCE metacommand is not present in the primary source file, or if no primary source file is available for checking, conversion of the RES file to a PBR file is then optional. That is, PBShell will try to run PBRES.EXE on the compiled RES file, but if it is unsuccessful, either because PBRES.EXE is not found or because PBRES.EXE does not produce a PBR file, it will not complain. Further, when no #RESOURCE is specified, the RES file will not be deleted whether PBR creation was successful or not.