What toolic said but you're better off in general, I argue, reaching for a module like Path::Tiny.
use strictures;
use Path::Tiny;
my $root = "some/place";
my $name = "somefile.ook";
my $path = path( $root, $name );
print $path, $/;
print $path->relative("some"), $/;
print $path->absolute, $/;
There are many advantages to this style especially in code that will grow; reading, writing, iterating, relative, absolute... all kinds of fun made simple and easy for others to follow when they read your code. (update: added a missing comma.)