Well, if you look at your C source code and at the source code provided in the pdf sample, you can see that you've added a -duplicate- main proc;
Remove it (i.e. your source code without it):
#include "chello.h"
void PrintHello(){
printf("Hello\n");
return;
};
void PrintHelloS(int nme){
printf("Hello\n");
printf("%i",nme);
return;
};
Anyway, you'll also have to add an import library in your Free Pascal program. Something like (still modifying your source code):
{$IFDEF Unix}
{$linklib c}
{$ELSE}
{$linklib libmsvcrt}
{$ENDIF}
** Edit ** Duplicate post with Leledumbo.