From: Charles McGarvey Date: Fri, 18 Jan 2013 06:10:29 +0000 (-0700) Subject: add smarter shell-quoting in the cflags and libs functions X-Git-Tag: v0.03~2 X-Git-Url: https://git.dogcows.com/gitweb?p=chaz%2Fp5-Alien-ZMQ;a=commitdiff_plain;h=da7265e28350fae42a9173aae5d50cd004b88383 add smarter shell-quoting in the cflags and libs functions --- diff --git a/lib/Alien/ZMQ.pm b/lib/Alien/ZMQ.pm index 4c0e2f9..099edcc 100644 --- a/lib/Alien/ZMQ.pm +++ b/lib/Alien/ZMQ.pm @@ -4,6 +4,8 @@ package Alien::ZMQ; use warnings; use strict; +use String::ShellQuote qw/shell_quote/; + =head1 DESCRIPTION Upon installation, the target system is probed for the presence of libzmq. If @@ -118,7 +120,7 @@ is a shortcut for constructing a C<-I> flag using C. =cut sub cflags { - "-I'" . inc_dir . "'"; + "-I" . shell_quote(inc_dir); } =method libs @@ -129,7 +131,7 @@ a shortcut for constructing a C<-L> flag using C, plus C<-lzmq>. =cut sub libs { - "-L'" . lib_dir . "' -lzmq"; + "-L" . shell_quote(lib_dir) . " -lzmq"; } 1;