Removed --enable-silc-plugin. Added --with-silc-plugin.
[silc.git] / apps / irssi / configure.in
index 12acfaffcdb45239d6096d1f1e1e31c17a3f5fad..109e5b2cf11e94d6845595b5422f7c7fa72e886b 100644 (file)
@@ -191,14 +191,33 @@ AC_ARG_WITH(perl,
 
 # Irssi SILC Plugin support
 #
-AC_ARG_ENABLE(silc-plugin,
-[  --enable-silc-plugin    Compile the SILC Plugin instead of the SILC Client],
-[case "${enableval}" in
-  yes) silc_plugin=true ;;
-  no)  silc_plugin=false ;;
-  *) AC_MSG_ERROR(bad value ${enableval} for --enable-silc-plugin) ;;
-esac],[silc_plugin=false])
+SILC_IRSSIDIR=
+silc_plugin=false
+AC_MSG_CHECKING(whether to compile SILC Plugin for Irssi)
+AC_ARG_WITH(silc-plugin,
+  [[  --with-silc-plugin[=DIR] Compile the SILC Plugin for Irssi, specify
+                           Irssi location [/usr/lib/irssi]]],
+  [
+    case "${withval}" in
+      no)
+        AC_MSG_RESULT(no)
+        silc_plugin=false
+        ;;
+      yes)
+        AC_MSG_RESULT(yes)
+        silc_plugin=true
+       SILC_IRSSIDIR="/usr/lib/irssi/modules"
+       ;;
+      *)
+        AC_MSG_RESULT(yes)
+        silc_plugin=true
+        SILC_IRSSIDIR="$withval/modules"
+        ;;
+    esac
+  ])
+
 AM_CONDITIONAL(SILCPLUGIN, test x$silc_plugin = xtrue)
+AC_SUBST(SILC_IRSSIDIR)
 
 AC_ARG_WITH(file-offset-size,
 [  --with-file-offset-size=BITS  Set size of file offsets. Usually 32 or 64.