Fix pmdapapi warnings during compilation
Fix pmdapapi warnings during compilation

Move native component variables within the #ifdef, add explicit
assignment for first argument in for loop, change variable type.

andyvand/cygpcpfans,prasincs/pcp,wuliming/pcp,tjanez/pcp,adfernandes/pcp,aeg-aeg/pcpfans,andyvand/cygpcpfans,adfernandes/pcp,andyvand/cygpcpfans,adfernandes/pcp,prasincs/pcp,adfernandes/pcp,edwardt/pcp,tjanez/pcp,adfernandes/pcp,aeg-aeg/pcpfans,wuliming/pcp,wuliming/pcp,prasincs/pcp,prasincs/pcp,andyvand/cygpcpfans,edwardt/pcp,prasincs/pcp,edwardt/pcp,adfernandes/pcp,wuliming/pcp,andyvand/cygpcpfans,wuliming/pcp,tjanez/pcp,edwardt/pcp,aeg-aeg/pcpfans,tjanez/pcp,adfernandes/pcp,andyvand/cygpcpfans,aeg-aeg/pcpfans,adfernandes/pcp,prasincs/pcp,aeg-aeg/pcpfans,andyvand/cygpcpfans,wuliming/pcp,tjanez/pcp,tjanez/pcp,edwardt/pcp,edwardt/pcp,prasincs/pcp,andyvand/cygpcpfans,tjanez/pcp,edwardt/pcp,aeg-aeg/pcpfans,aeg-aeg/pcpfans,wuliming/pcp,prasincs/pcp,wuliming/pcp,aeg-aeg/pcpfans,edwardt/pcp,tjanez/pcp