]>
jfr.im git - irc/evilnet/znc.git/blob - znc-buildmod.in
7 # Check if we got everything we need
11 which $1 > /dev
/null
2>&1
13 echo "${ERROR} Could not find $1. $2"
18 if test "x$CXX" = "x" ; then
21 if test "x$CXX" = "x" ; then
25 check_binary
${CXX} "What happened to your compiler?"
28 echo "${WARNING} USAGE: $0 <file.cpp> [file.cpp ... ]"
32 CXXFLAGS
="@CPPFLAGS@ @MODFLAGS@ -I@prefix@/include $CXXFLAGS"
34 MODLINK
="@MODLINK@ $MODLINK"
35 VERSION
="@PACKAGE_VERSION@"
37 # Ugly cygwin stuff :(
38 if test -n "@LIBZNC@"; then
40 exec_prefix
="@exec_prefix@"
41 LDFLAGS
="-L@libdir@ $LDFLAGS"
54 if test ! -f "${FILE}"; then
55 echo "${ERROR} Building \"${MOD}\" for ZNC $VERSION... File not found"
58 printf "Building \"${MOD}.so\" for ZNC $VERSION... "
59 if ${CXX} ${CXXFLAGS} ${INCLUDES} ${LDFLAGS} ${MODLINK} -o "${MOD}.so" "${FILE}" ${LIBS} ; then
62 echo "${ERROR} Error while building \"${MOD}.so\""