diff options
author | Martin Wilke <miwi@FreeBSD.org> | 2009-11-21 11:27:21 +0000 |
---|---|---|
committer | Martin Wilke <miwi@FreeBSD.org> | 2009-11-21 11:27:21 +0000 |
commit | abd465fc53774d534f6791f69b9a3a707c356b3b (patch) | |
tree | b7388add9f7f65f4ce18253bec863d079e69d566 /irc/weechat-devel/files | |
parent | - Update to 1.3.9 (diff) |
* Add TCL plugin option.
* Add build documentation option.
* Fix incorrect logic for charset option.
* Remove broken tag from Ruby option.
* Update option conditionals to be more readable
* Remove mandatory dependancies on Ruby, Perl and gettext, add them to
corresponding options as optional dependancies instead.
* Add missing .pl NLS message catalog to plist.
PR: 140603
Submitted by: Jase Thew <freebsd@beardz.net>
Notes
Notes:
svn path=/head/; revision=244592
Diffstat (limited to 'irc/weechat-devel/files')
-rw-r--r-- | irc/weechat-devel/files/patch-configure.in | 29 | ||||
-rw-r--r-- | irc/weechat-devel/files/patch-src-plugins-scripts-script_c | 168 |
2 files changed, 197 insertions, 0 deletions
diff --git a/irc/weechat-devel/files/patch-configure.in b/irc/weechat-devel/files/patch-configure.in new file mode 100644 index 000000000000..5510d034332d --- /dev/null +++ b/irc/weechat-devel/files/patch-configure.in @@ -0,0 +1,29 @@ +--- configure.in.orig 2009-09-06 08:01:26.000000000 +0000 ++++ configure.in 2009-11-12 14:46:30.000000000 +0000 +@@ -137,6 +137,7 @@ + AC_ARG_WITH(lua-inc, [ --with-lua-inc=DIR, lua include files are in DIR (default=autodetect)],lua_inc=$withval,lua_inc='') + AC_ARG_WITH(lua-lib, [ --with-lua-lib=DIR, lua library files are in DIR (default=autodetect)],lua_lib=$withval,lua_lib='') + AC_ARG_WITH(lua-suffix, [ --with-lua-suffix=ARG lua is suffixed with ARG (default=autodetect)],lua_suffix=$withval,lua_suffix='') ++AC_ARG_WITH(tclconfig, [ --with-tclconfig=DIR directory containing tcl configuration (tclConfig.sh)],tclconfig=$withval,tclconfig='') + AC_ARG_ENABLE(doc, [ --disable-doc turn off documentation (default=built)],enable_doc=$enableval,enable_doc=yes) + AC_ARG_WITH(debug, [ --with-debug debugging: 0=no debug, 1=debug compilation (default=1)],debug=$withval,debug=1) + +@@ -682,6 +683,9 @@ + AC_MSG_CHECKING(for tclConfig.sh) + tcl_found="no" + tcl_dirs="/lib /usr/lib /usr/tcl/lib /usr/lib/tcl8.5 /usr/lib/tcl8.4 /usr/lib/tcl8.3 /usr/local/lib /usr/local/tcl-8.5/lib /usr/local/tcl-8.4/lib /usr/local/tcl-8.3/lib /usr/local/tcl/lib /opt/lib" ++ if test "x$tclconfig" != "x" ; then ++ tcl_dirs="$tclconfig $tcl_dirs" ++ fi + for tcl_dir in $tcl_dirs ; do + if test -f ${tcl_dir}/tclConfig.sh ; then + . ${tcl_dir}/tclConfig.sh +@@ -870,7 +874,7 @@ + AC_MSG_RESULT(no) + fi + +-CFLAGS=`echo $CFLAGS | sed 's/ -g //g'` ++CFLAGS=`echo $CFLAGS | sed 's/ -g / /g'` + CFLAGS=`echo $CFLAGS | sed 's/^-g //g'` + CFLAGS=`echo $CFLAGS | sed 's/ -g$//g'` + CFLAGS=`echo $CFLAGS | sed 's/^-g$//g'` diff --git a/irc/weechat-devel/files/patch-src-plugins-scripts-script_c b/irc/weechat-devel/files/patch-src-plugins-scripts-script_c new file mode 100644 index 000000000000..1c935827582e --- /dev/null +++ b/irc/weechat-devel/files/patch-src-plugins-scripts-script_c @@ -0,0 +1,168 @@ +--- src/plugins/scripts/script.c.orig 2009-09-04 08:25:47.000000000 +0000 ++++ src/plugins/scripts/script.c 2009-11-16 12:08:54.000000000 +0000 +@@ -439,24 +439,15 @@ + script_search_by_full_name (struct t_plugin_script *scripts, + const char *full_name) + { +- char *full_name_copy, *base_name; ++ char *base_name; + struct t_plugin_script *ptr_script; + +- full_name_copy = strdup (full_name); +- +- if (full_name_copy) ++ for (ptr_script = scripts; ptr_script; ++ ptr_script = ptr_script->next_script) + { +- for (ptr_script = scripts; ptr_script; +- ptr_script = ptr_script->next_script) +- { +- base_name = basename (ptr_script->filename); +- if (strcmp (base_name, full_name) == 0) +- { +- free (full_name_copy); +- return ptr_script; +- } +- } +- free (full_name_copy); ++ base_name = basename (ptr_script->filename); ++ if (strcmp (base_name, full_name) == 0) ++ return ptr_script; + } + + /* script not found */ +@@ -915,7 +906,8 @@ + int (*script_load)(const char *filename), + char **list) + { +- char **argv, *name, *base_name, *new_path, *autoload_path, *symlink_path; ++ char **argv, *name, *ptr_base_name, *base_name, *new_path, *autoload_path; ++ char *symlink_path; + const char *dir_home, *dir_separator; + int argc, i, length; + struct t_plugin_script *ptr_script; +@@ -930,67 +922,71 @@ + name = strdup (argv[i]); + if (name) + { +- base_name = basename (name); +- +- /* unload script, if script is loaded */ +- ptr_script = script_search_by_full_name (scripts, base_name); +- if (ptr_script) +- (*script_unload) (ptr_script); ++ ptr_base_name = basename (name); ++ base_name = strdup (ptr_base_name); ++ if (base_name) ++ { ++ /* unload script, if script is loaded */ ++ ptr_script = script_search_by_full_name (scripts, base_name); ++ if (ptr_script) ++ (*script_unload) (ptr_script); + +- /* remove script file(s) */ +- script_remove_file (weechat_plugin, base_name, 0); ++ /* remove script file(s) */ ++ script_remove_file (weechat_plugin, base_name, 0); + +- /* move file from install dir to language dir */ +- dir_home = weechat_info_get ("weechat_dir", ""); +- length = strlen (dir_home) + strlen (weechat_plugin->name) + +- strlen (base_name) + 16; +- new_path = malloc (length); +- if (new_path) +- { +- snprintf (new_path, length, "%s/%s/%s", +- dir_home, weechat_plugin->name, base_name); +- if (rename (name, new_path) == 0) ++ /* move file from install dir to language dir */ ++ dir_home = weechat_info_get ("weechat_dir", ""); ++ length = strlen (dir_home) + strlen (weechat_plugin->name) + ++ strlen (base_name) + 16; ++ new_path = malloc (length); ++ if (new_path) + { +- /* make link in autoload dir */ +- length = strlen (dir_home) + +- strlen (weechat_plugin->name) + 8 + +- strlen (base_name) + 16; +- autoload_path = malloc (length); +- if (autoload_path) ++ snprintf (new_path, length, "%s/%s/%s", ++ dir_home, weechat_plugin->name, base_name); ++ if (rename (name, new_path) == 0) + { +- snprintf (autoload_path, length, +- "%s/%s/autoload/%s", +- dir_home, weechat_plugin->name, +- base_name); +- dir_separator = weechat_info_get ("dir_separator", ""); +- length = 2 + strlen (dir_separator) + +- strlen (base_name) + 1; +- symlink_path = malloc (length); +- if (symlink_path) ++ /* make link in autoload dir */ ++ length = strlen (dir_home) + ++ strlen (weechat_plugin->name) + 8 + ++ strlen (base_name) + 16; ++ autoload_path = malloc (length); ++ if (autoload_path) + { +- snprintf (symlink_path, length, "..%s%s", +- dir_separator, base_name); +- symlink (symlink_path, autoload_path); +- free (symlink_path); +- } ++ snprintf (autoload_path, length, ++ "%s/%s/autoload/%s", ++ dir_home, weechat_plugin->name, ++ base_name); ++ dir_separator = weechat_info_get ("dir_separator", ""); ++ length = 2 + strlen (dir_separator) + ++ strlen (base_name) + 1; ++ symlink_path = malloc (length); ++ if (symlink_path) ++ { ++ snprintf (symlink_path, length, "..%s%s", ++ dir_separator, base_name); ++ symlink (symlink_path, autoload_path); ++ free (symlink_path); ++ } + free (autoload_path); +- } ++ } + +- /* load script */ +- (*script_load) (new_path); +- } +- else +- { +- weechat_printf (NULL, +- _("%s%s: failed to move script %s " +- "to %s (%s)"), +- weechat_prefix ("error"), +- weechat_plugin->name, +- name, +- new_path, +- strerror (errno)); ++ /* load script */ ++ (*script_load) (new_path); ++ } ++ else ++ { ++ weechat_printf (NULL, ++ _("%s%s: failed to move script %s " ++ "to %s (%s)"), ++ weechat_prefix ("error"), ++ weechat_plugin->name, ++ name, ++ new_path, ++ strerror (errno)); ++ } ++ free (new_path); + } +- free (new_path); ++ free (base_name); + } + free (name); + } |