This output looks strange to me. It appears that there are two different user accounts involved (/Users/ad and /Users/fc). It appears that you are trying to run the cpan command when you are logged into the ad account, but you installed the brewed perl in the fc account. Is that the case? I always use brewed perls from the same account that I used to install them. Try to confirm that you are using the cpan executable from your brewed perl. Typing this at the command line,
should give you output like this,
If the output is /usr/bin/cpan, then you are still using the cpan command that is part of the system perl. After you installed perl-5.26.1 did you switch to it with the following command?
perlbrew switch perl-5.26.1
If you did not run the switch command then you are still using the system perl (which is probably not what you want).
Once you confirm that you are using your brewed perl, I recommend that you install cpanminus (see App::cpanminus) using the following command,
curl -L https://cpanmin.us | perl - App::cpanminus
Then you can use cpanm
to install modules (I find that its easier to use than the older cpan