PWM using XC8 compiler and peripheral libraries
I have solved my question. 

The problem is that I was using the 1.40 version of XC8 compiler. The periperial libraries are not longer supported and were compiled with version 1.34 of MPLAB XC8. Any changes made to header files since those libraries were created could potentially create a declaration mismatch. 

What I did was download the former 1.34 version of XC8 ( http://ww1.microchip.com/downloads/en/DeviceDoc/xc8-v1.34-full-install-windows-installer.exe ) and installed it. After that I chose to work with that version of the compiler and my code now works fine