Hello community,

here is the log from the commit of package yast2-slp for openSUSE:Factory 
checked in at 2013-08-01 11:09:59
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/yast2-slp (Old)
 and      /work/SRC/openSUSE:Factory/.yast2-slp.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "yast2-slp"

Changes:
--------
--- /work/SRC/openSUSE:Factory/yast2-slp/yast2-slp.changes      2013-02-15 
18:56:18.000000000 +0100
+++ /work/SRC/openSUSE:Factory/.yast2-slp.new/yast2-slp.changes 2013-08-01 
11:10:01.000000000 +0200
@@ -1,0 +2,7 @@
+Wed Jul 31 08:39:31 UTC 2013 - [email protected]
+
+- converted from YCP to Ruby by YCP Killer
+  (https://github.com/yast/ycp-killer)
+- version 3.0.0
+
+-------------------------------------------------------------------

Old:
----
  yast2-slp-2.23.0.tar.bz2

New:
----
  yast2-slp-3.0.0.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ yast2-slp.spec ++++++
--- /var/tmp/diff_new_pack.1iNUAE/_old  2013-08-01 11:10:02.000000000 +0200
+++ /var/tmp/diff_new_pack.1iNUAE/_new  2013-08-01 11:10:02.000000000 +0200
@@ -17,7 +17,7 @@
 
 
 Name:           yast2-slp
-Version:        2.23.0
+Version:        3.0.0
 Release:        0
 
 BuildRoot:      %{_tmppath}/%{name}-%{version}-build
@@ -38,6 +38,8 @@
 # Wizard::SetDesktopTitleAndIcon
 Requires:       yast2 >= 2.21.22
 
+Requires:       yast2-ruby-bindings >= 1.0.0
+
 Summary:        YaST2 - SLP Agent and Browser
 License:        GPL-2.0+
 Group:          System/YaST
@@ -79,9 +81,8 @@
 %{_libdir}/YaST2/plugin/libpy2ag_slp.so.*
 %{_libdir}/YaST2/plugin/libpy2ag_slp.so
 %{_libdir}/YaST2/plugin/libpy2ag_slp.la
-/usr/share/YaST2/clients/slp.ycp
-#%{_prefix}/share/applications/YaST2/slp.desktop
-/usr/share/YaST2/modules/SLP.y*
+/usr/share/YaST2/clients/slp.rb
+/usr/share/YaST2/modules/SLP.rb
 %doc %{_prefix}/share/doc/packages/yast2-slp
 
 %changelog

++++++ yast2-slp-2.23.0.tar.bz2 -> yast2-slp-3.0.0.tar.bz2 ++++++
++++ 1880 lines of diff (skipped)
++++    retrying with extended exclude list
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/Makefile.am new/yast2-slp-3.0.0/Makefile.am
--- old/yast2-slp-2.23.0/Makefile.am    2013-02-14 16:36:43.000000000 +0100
+++ new/yast2-slp-3.0.0/Makefile.am     2013-07-31 10:47:28.000000000 +0200
@@ -158,19 +158,14 @@
 
 TAGVERSION      = $(Y2TOOL) tagversion
 
-check-up-to-date check-cvs-up-to-date check-svn-up-to-date:
-       if [ -d $(srcdir)/CVS ]; then \
-         cd $(srcdir) && ! cvs -q -n up 2>/dev/null | grep '^[MCAR] ';\
-       else \
-         cd $(srcdir) && ! LC_ALL=C svn status --show-updates --quiet | grep 
-v '^Status against revision' ;\
+# check if there is no modified files and all commits were pushed
+check-up-to-date:
+       if [ `git status --short --branch | sed '/##[^[]*$/d;/^??/d' | wc -l` 
-gt 0 ]; then \
+         (echo "ERROR: Source is not commited and pushed. See `git status`"; 
false) \
        fi
 
 check-tagversion:
-       @if [ -d $(srcdir)/CVS ]; then \
-         cd $(srcdir) && cvs status -v VERSION | grep -w `$(TAGVERSION) -n` ;\
-       else \
-         cd $(srcdir) && svn cat `$(TAGVERSION) --echourl`/VERSION; \
-       fi >/dev/null; \
+       cd $(srcdir) && $(TAGVERSION) --check >/dev/null; \
        [ $$? = 0 ] || ( echo "ERROR: Please run 'tagversion' first"; false )
 
 check-parse-old:
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/Makefile.am.common new/yast2-slp-3.0.0/Makefile.am.common
--- old/yast2-slp-2.23.0/Makefile.am.common     2013-02-14 16:36:43.000000000 
+0100
+++ new/yast2-slp-3.0.0/Makefile.am.common      2013-07-31 10:47:28.000000000 
+0200
@@ -31,7 +31,7 @@
 
 CHECK_SYNTAX = true
 check-syntax: $(client_DATA) $(ycpchook) $(ybcfiles)
-       @if test "$(client_DATA)"; then \
+       @if test "$(filter %.ycp,client_DATA)"; then \
          if $(CHECK_SYNTAX); then \
            TO_CHECK="$(filter %.ycp,$^)"; \
            echo "Checking syntax of $${TO_CHECK}"; \
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/VERSION new/yast2-slp-3.0.0/VERSION
--- old/yast2-slp-2.23.0/VERSION        2013-02-14 16:36:34.000000000 +0100
+++ new/yast2-slp-3.0.0/VERSION 2013-07-30 13:41:05.000000000 +0200
@@ -1 +1 @@
-2.23.0
+3.0.0
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/autodocs-cc-base.ami 
new/yast2-slp-3.0.0/autodocs-cc-base.ami
--- old/yast2-slp-2.23.0/autodocs-cc-base.ami   2013-02-14 16:36:43.000000000 
+0100
+++ new/yast2-slp-3.0.0/autodocs-cc-base.ami    2013-07-31 10:47:28.000000000 
+0200
@@ -15,7 +15,7 @@
 AUTODOCS_CC ?= $(srcdir)/../../src
 AUTODOCS_DEPS ?= $(AUTODOCS_CC)/*.h
 
-html_data = index.html $(filter-out index.html, $(wildcard *.html *.png)) 
doxygen.css @[email protected]
+html_data = index.html $(filter-out index.html, $(wildcard *.html *.png *.css 
*.js)) @[email protected]
 CLEANFILES = $(html_data) doxygen.log doxygen.conf installdox
 
 doxygen.css @[email protected]: index.html
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/autodocs-ycp.ami new/yast2-slp-3.0.0/autodocs-ycp.ami
--- old/yast2-slp-2.23.0/autodocs-ycp.ami       2013-02-14 16:36:43.000000000 
+0100
+++ new/yast2-slp-3.0.0/autodocs-ycp.ami        2013-07-31 10:47:28.000000000 
+0200
@@ -8,6 +8,8 @@
 #                Optional - the default is $(srcdir)/../../src/*.ycp
 #   AUTODOCS_PM: Files that the perl autodocs is built from
 #                Optional - the default is $(srcdir)/../../src/*.pm
+#   AUTODOCS_RB: Files that the ruby autodocs is built from (using yard)
+#                Optional - the default is $(srcdir)/../../src/modules/*.rb) 
$(srcdir)/../../src/include/*/*.rb
 #   AUTODOCS_SUBDIR: To install the result to $(docdir)/SUBDIR/autodocs
 #              Optional - the default is no subdir, $(docdir)/autodocs
 #   AUTODOCS_STRIP: Strip it from filenames. The remaining / are replaced by __
@@ -15,18 +17,31 @@
 
 htmldir = $(docdir)/$(AUTODOCS_SUBDIR)/autodocs
 
-html_DATA = index.html $(filter-out index.html, $(wildcard *.html))
-CLEANFILES = $(html_DATA) pod2htm*.tmp
+# use nobase_ prefix to keep the directory structure
+nobase_html_DATA = index.html $(filter-out index.html, $(wildcard *.html)) 
$(wildcard js/*) $(wildcard css/*) $(wildcard Yast/*)
+CLEANFILES = $(nobase_html_DATA) pod2htm*.tmp
 
 AUTODOCS_YCP ?= $(wildcard $(srcdir)/../../src/*.ycp)
 AUTODOCS_PM  ?= $(wildcard $(srcdir)/../../src/*.pm)
+AUTODOCS_RB  ?= $(wildcard $(srcdir)/../../src/modules/*.rb 
$(srcdir)/../../src/include/*/*.rb)
 AUTODOCS_STRIP ?= $(srcdir)/../../src
 
-index.html: $(AUTODOCS_YCP) $(AUTODOCS_PM)
+# yard specific options
+YARD ?= yard
+# use markdown format by default
+YARD_OPTIONS ?= -o . -m markdown
+
+# yard specific clean
+clean-local:
+       rm -rf js css Yast .yardoc
+
+
+index.html: $(AUTODOCS_YCP) $(AUTODOCS_PM) $(AUTODOCS_RB)
 #including *.pm, for the index
-       ${YCPDOC} -d. -s$(AUTODOCS_STRIP) $(AUTODOCS_YCP)
+       if [ -n "$(AUTODOCS_YCP)" ]; then ${YCPDOC} -d. -s$(AUTODOCS_STRIP) 
$(AUTODOCS_YCP); fi
        for i in $(AUTODOCS_PM); do \
                b=$${i##$(AUTODOCS_STRIP)}; b=$${b#/}; b=$${b//\//__}; 
b=$${b%.pm}; \
                pod2html --title=$$b --infile=$$i --outfile=$$b.html; \
                echo "<a href='$$b.html'>$${b/__/::}</a>" > $$b.mod.html; \
        done
+       if [ -n "$(AUTODOCS_RB)" ]; then $(YARD) doc --title "@RPMNAME@ -- 
Development Documentation" $(YARD_OPTIONS) $(AUTODOCS_RB); fi
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/config.h.in new/yast2-slp-3.0.0/config.h.in
--- old/yast2-slp-2.23.0/config.h.in    2013-02-14 16:36:55.000000000 +0100
+++ new/yast2-slp-3.0.0/config.h.in     2013-07-31 10:47:39.000000000 +0200
@@ -1,4 +1,4 @@
-/* config.h.in.  Generated from configure.in by autoheader.  */
+/* config.h.in.  Generated from configure.ac by autoheader.  */
 
 /* Define to one of `_getb67', `GETB67', `getb67' for Cray-2 and Cray-YMP
    systems. This function is required for `alloca.c' support on those systems.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/configure.ac new/yast2-slp-3.0.0/configure.ac
--- old/yast2-slp-2.23.0/configure.ac   1970-01-01 01:00:00.000000000 +0100
+++ new/yast2-slp-3.0.0/configure.ac    2013-07-31 10:47:28.000000000 +0200
@@ -0,0 +1,206 @@
+dnl configure.ac for yast2-slp
+dnl
+dnl -- This file is generated by y2autoconf 2.24.7 - DO NOT EDIT! --
+dnl    (edit configure.ac.in or configure.in.in instead)
+
+AC_INIT(yast2-slp, 3.0.0, http://bugs.opensuse.org/, yast2-slp)
+dnl Check for presence of file 'RPMNAME'
+AC_CONFIG_SRCDIR([RPMNAME])
+
+dnl Checking host/target/build systems, for make, install etc.
+AC_CANONICAL_TARGET
+dnl Perform program name transformation
+AC_ARG_PROGRAM
+
+AC_PREFIX_DEFAULT(/usr)
+
+dnl long filenames; we use GNU Make extensions and that's ok
+AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)
+
+dnl Important YaST2 variables
+VERSION="3.0.0"
+RPMNAME="yast2-slp"
+MAINTAINER="Jiri Suchomel <[email protected]>"
+
+dnl pkgconfig honors lib64
+pkgconfigdir=\${libdir}/pkgconfig
+pkgconfigdatadir=\${datadir}/pkgconfig
+yast2dir=\${prefix}/share/YaST2
+
+ybindir=\${prefix}/lib/YaST2/bin
+# FIXME duplicates execcompdir
+ystartupdir=\${prefix}/lib/YaST2
+plugindir=\${libdir}/YaST2/plugin
+includedir=\${prefix}/include/YaST2
+potdir=\${docdir}/pot
+
+docdir=\${prefix}/share/doc/packages/$RPMNAME
+mandir=\${prefix}/share/man
+
+execcompdir=\${prefix}/lib/YaST2
+agentdir=${execcompdir}/servers_non_y2
+
+ydatadir=${yast2dir}/data
+imagedir=${yast2dir}/images
+themedir=${yast2dir}/theme
+localedir=${yast2dir}/locale
+clientdir=${yast2dir}/clients
+moduledir=${yast2dir}/modules
+yncludedir=${yast2dir}/include
+schemadir=${yast2dir}/schema
+scrconfdir=${yast2dir}/scrconf
+desktopdir=\${prefix}/share/applications/YaST2
+
+AC_SUBST(VERSION)
+AC_SUBST(RPMNAME)
+AC_SUBST(MAINTAINER)
+
+AC_SUBST(pkgconfigdir)
+AC_SUBST(pkgconfigdatadir)
+
+AC_SUBST(yast2dir)
+
+AC_SUBST(ybindir)
+AC_SUBST(ystartupdir)
+AC_SUBST(plugindir)
+AC_SUBST(includedir)
+AC_SUBST(potdir)
+AC_SUBST(execcompdir)
+
+AC_SUBST(docdir)
+AC_SUBST(mandir)
+
+AC_SUBST(ydatadir)
+AC_SUBST(imagedir)
+AC_SUBST(themedir)
+AC_SUBST(localedir)
+AC_SUBST(clientdir)
+AC_SUBST(moduledir)
+AC_SUBST(yncludedir)
+AC_SUBST(schemadir)
+AC_SUBST(scrconfdir)
+AC_SUBST(agentdir)
+AC_SUBST(desktopdir)
+
+fillupdir_d="/var/adm/fillup-templates"
+AC_ARG_WITH(fillupdir,
+    AS_HELP_STRING([--with-fillupdir=DIR],
+                  [where to place fillup templates (default $fillupdir_d.]),
+    [ fillupdir="$withval" ],
+    [ fillupdir="$fillupdir_d" ])
+AC_SUBST(fillupdir)
+
+dnl Automake 1.11 enables silent compilation,
+dnl Disable it by "configure --disable-silent-rules" or "make V=1"
+m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
+
+
+dnl Checks for programs.
+AC_PROG_INSTALL
+dnl The YCP interpreter checks whether dependent ybc files are older
+dnl so we must preserve their timestamps
+INSTALL="${INSTALL} -p"
+AC_PROG_LN_S
+AC_PROG_MAKE_SET
+
+dnl pkgconfig
+AC_ARG_VAR([PKG_CONFIG_PATH], [where to search for pkg-config files])
+dnl devtools
+dnl ...
+
+dnl no need for AC_ARG_VAR
+AC_PATH_PROG(XGETTEXT, xgettext)
+if test -z "$XGETTEXT" ; then
+    AC_MSG_ERROR(xgettext is missing; please install gettext-tools.)
+fi
+
+Y2DEVTOOLS_PREFIX=`pkg-config --print-errors --variable=prefix yast2-devtools`
+AC_SUBST(Y2DEVTOOLS_PREFIX)
+devtools_ybindir=`pkg-config --print-errors --variable=ybindir yast2-devtools`
+devtools_yast2dir=`pkg-config --print-errors --variable=yast2dir 
yast2-devtools`
+
+dnl producing pkg-config for others?
+AM_CONDITIONAL(CREATE_PKGCONFIG, test "x${CREATE_PKGCONFIG}" != x)
+AM_CONDITIONAL(CREATE_PKGCONFIG_NOARCH, test "x${CREATE_PKGCONFIG}" = xnoarch)
+
+dbdir=${devtools_yast2dir}/data/docbook
+STYLESHEET_HTML=${dbdir}/stylesheets/customize-html.xsl
+STYLESHEET_PDF=${dbdir}/stylesheets/customize-fo.xsl
+STYLESHEET_CSS=${dbdir}/css/yast2docs.css
+STYLESHEET_YDOC=${dbdir}/stylesheets/ydoc.xsl
+STYLESHEET_YCPDOC=${dbdir}/stylesheets/ycpdoc.xsl
+AC_SUBST(STYLESHEET_HTML)
+AC_SUBST(STYLESHEET_PDF)
+AC_SUBST(STYLESHEET_CSS)
+AC_SUBST(STYLESHEET_YDOC)
+AC_SUBST(STYLESHEET_YCPDOC)
+
+
+
+AC_PATH_PROG(YDOXYGEN, ydoxygen, false, $PATH:$devtools_ybindir)
+if test "$YDOXYGEN" = "false"; then
+    AC_MSG_ERROR([ydoxygen is not installed])
+fi
+
+AC_PROG_CXX
+AC_PROG_AWK
+AC_PROG_CC
+AC_PROG_CPP
+
+# If we have core, get its Y2CORE_CFLAGS.
+# When building core itself, it has set Y2CORE_CFLAGS elsewhere already
+PKG_CHECK_EXISTS([yast2-core],[
+    PKG_CHECK_MODULES(Y2CORE, yast2-core)
+])
+
+CFLAGS="${CFLAGS} -Wall -Wformat=2 -Wmissing-prototypes"
+CXXFLAGS="${CXXFLAGS} ${Y2CORE_CFLAGS} -Wall -Wformat=2"
+
+: ${AGENT_LIBADD:='-L$(libdir) -lscr -ly2util -lycpvalues'}
+AC_SUBST(AGENT_LIBADD)
+
+AC_DISABLE_STATIC
+AC_PROG_LIBTOOL
+AM_PROG_LIBTOOL dnl for libraries
+
+dnl generate the config header
+AC_CONFIG_HEADERS([config.h]) dnl at the distribution this done
+
+AC_FUNC_ALLOCA
+AC_HEADER_STDC
+
+AC_PATH_PROG(YCPDOC, ycpdoc, false, $PATH:$devtools_ybindir)
+if test "$YCPDOC" = "false"; then
+    AC_MSG_ERROR([ycpdoc is not installed])
+fi
+AC_PATH_PROG(YCPMAKEDEP, ycpmakedep, false, $PATH:$devtools_ybindir)
+if test "$YCPMAKEDEP" = "false"; then
+    AC_MSG_ERROR([ycpmakedep is not installed])
+fi
+AC_PATH_PROG(YCPC, ycpc, false, $PATH:$bindir)
+if test "$YCPC" = "false"; then
+    AC_MSG_ERROR([ycpc is not installed])
+fi
+AC_CHECK_FILE($devtools_yast2dir/data/testsuite/Makefile.testsuite, [], [
+    AC_MSG_WARN([yast2-testsuite.rpm is not installed])
+])
+
+
+# check slp.h
+yast_found_slp=no
+AC_CHECK_HEADER([slp.h],[yast_found_slp=yes])
+if test "$yast_found_slp" = "no"; then
+    AC_MSG_ERROR([Header file slp.h is missing. Please install openslp-devel.])
+fi
+
+AC_CONFIG_FILES(Makefile agent-slp/conf/Makefile
+agent-slp/src/Makefile
+agent-slp/doc/autodocs/Makefile
+agent-slp/doc/Makefile
+agent-slp/Makefile
+doc/autodocs/Makefile
+doc/Makefile
+src/Makefile
+testsuite/Makefile)
+AC_OUTPUT
+
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/configure.in new/yast2-slp-3.0.0/configure.in
--- old/yast2-slp-2.23.0/configure.in   2013-02-14 16:36:43.000000000 +0100
+++ new/yast2-slp-3.0.0/configure.in    1970-01-01 01:00:00.000000000 +0100
@@ -1,206 +0,0 @@
-dnl configure.in for yast2-slp
-dnl
-dnl -- This file is generated by y2autoconf 2.23.2 - DO NOT EDIT! --
-dnl    (edit configure.in.in instead)
-
-AC_INIT(yast2-slp, 2.23.0, http://bugs.opensuse.org/, yast2-slp)
-dnl Check for presence of file 'RPMNAME'
-AC_CONFIG_SRCDIR([RPMNAME])
-
-dnl Checking host/target/build systems, for make, install etc.
-AC_CANONICAL_TARGET
-dnl Perform program name transformation
-AC_ARG_PROGRAM
-
-AC_PREFIX_DEFAULT(/usr)
-
-dnl long filenames; we use GNU Make extensions and that's ok
-AM_INIT_AUTOMAKE(tar-ustar -Wno-portability)
-
-dnl Important YaST2 variables
-VERSION="2.23.0"
-RPMNAME="yast2-slp"
-MAINTAINER="Jiri Suchomel <[email protected]>"
-
-dnl pkgconfig honors lib64
-pkgconfigdir=\${libdir}/pkgconfig
-pkgconfigdatadir=\${datadir}/pkgconfig
-yast2dir=\${prefix}/share/YaST2
-
-ybindir=\${prefix}/lib/YaST2/bin
-# FIXME duplicates execcompdir
-ystartupdir=\${prefix}/lib/YaST2
-plugindir=\${libdir}/YaST2/plugin
-includedir=\${prefix}/include/YaST2
-potdir=\${docdir}/pot
-
-docdir=\${prefix}/share/doc/packages/$RPMNAME
-mandir=\${prefix}/share/man
-
-execcompdir=\${prefix}/lib/YaST2
-agentdir=${execcompdir}/servers_non_y2
-
-ydatadir=${yast2dir}/data
-imagedir=${yast2dir}/images
-themedir=${yast2dir}/theme
-localedir=${yast2dir}/locale
-clientdir=${yast2dir}/clients
-moduledir=${yast2dir}/modules
-yncludedir=${yast2dir}/include
-schemadir=${yast2dir}/schema
-scrconfdir=${yast2dir}/scrconf
-desktopdir=\${prefix}/share/applications/YaST2
-
-AC_SUBST(VERSION)
-AC_SUBST(RPMNAME)
-AC_SUBST(MAINTAINER)
-
-AC_SUBST(pkgconfigdir)
-AC_SUBST(pkgconfigdatadir)
-
-AC_SUBST(yast2dir)
-
-AC_SUBST(ybindir)
-AC_SUBST(ystartupdir)
-AC_SUBST(plugindir)
-AC_SUBST(includedir)
-AC_SUBST(potdir)
-AC_SUBST(execcompdir)
-
-AC_SUBST(docdir)
-AC_SUBST(mandir)
-
-AC_SUBST(ydatadir)
-AC_SUBST(imagedir)
-AC_SUBST(themedir)
-AC_SUBST(localedir)
-AC_SUBST(clientdir)
-AC_SUBST(moduledir)
-AC_SUBST(yncludedir)
-AC_SUBST(schemadir)
-AC_SUBST(scrconfdir)
-AC_SUBST(agentdir)
-AC_SUBST(desktopdir)
-
-fillupdir_d="/var/adm/fillup-templates"
-AC_ARG_WITH(fillupdir,
-    AS_HELP_STRING([--with-fillupdir=DIR],
-                  [where to place fillup templates (default $fillupdir_d.]),
-    [ fillupdir="$withval" ],
-    [ fillupdir="$fillupdir_d" ])
-AC_SUBST(fillupdir)
-
-dnl Automake 1.11 enables silent compilation,
-dnl Disable it by "configure --disable-silent-rules" or "make V=1"
-m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
-
-
-dnl Checks for programs.
-AC_PROG_INSTALL
-dnl The YCP interpreter checks whether dependent ybc files are older
-dnl so we must preserve their timestamps
-INSTALL="${INSTALL} -p"
-AC_PROG_LN_S
-AC_PROG_MAKE_SET
-
-dnl pkgconfig
-AC_ARG_VAR([PKG_CONFIG_PATH], [where to search for pkg-config files])
-dnl devtools
-dnl ...
-
-dnl no need for AC_ARG_VAR
-AC_PATH_PROG(XGETTEXT, xgettext)
-if test -z "$XGETTEXT" ; then
-    AC_MSG_ERROR(xgettext is missing; please install gettext-tools.)
-fi
-
-Y2DEVTOOLS_PREFIX=`pkg-config --print-errors --variable=prefix yast2-devtools`
-AC_SUBST(Y2DEVTOOLS_PREFIX)
-devtools_ybindir=`pkg-config --print-errors --variable=ybindir yast2-devtools`
-devtools_yast2dir=`pkg-config --print-errors --variable=yast2dir 
yast2-devtools`
-
-dnl producing pkg-config for others?
-AM_CONDITIONAL(CREATE_PKGCONFIG, test "x${CREATE_PKGCONFIG}" != x)
-AM_CONDITIONAL(CREATE_PKGCONFIG_NOARCH, test "x${CREATE_PKGCONFIG}" = xnoarch)
-
-dbdir=${devtools_yast2dir}/data/docbook
-STYLESHEET_HTML=${dbdir}/stylesheets/customize-html.xsl
-STYLESHEET_PDF=${dbdir}/stylesheets/customize-fo.xsl
-STYLESHEET_CSS=${dbdir}/css/yast2docs.css
-STYLESHEET_YDOC=${dbdir}/stylesheets/ydoc.xsl
-STYLESHEET_YCPDOC=${dbdir}/stylesheets/ycpdoc.xsl
-AC_SUBST(STYLESHEET_HTML)
-AC_SUBST(STYLESHEET_PDF)
-AC_SUBST(STYLESHEET_CSS)
-AC_SUBST(STYLESHEET_YDOC)
-AC_SUBST(STYLESHEET_YCPDOC)
-
-
-
-AC_PATH_PROG(YDOXYGEN, ydoxygen, false, $PATH:$devtools_ybindir)
-if test "$YDOXYGEN" = "false"; then
-    AC_MSG_ERROR([ydoxygen is not installed])
-fi
-
-AC_PROG_CXX
-AC_PROG_AWK
-AC_PROG_CC
-AC_PROG_CPP
-
-# If we have core, get its Y2CORE_CFLAGS.
-# When building core itself, it has set Y2CORE_CFLAGS elsewhere already
-PKG_CHECK_EXISTS([yast2-core],[
-    PKG_CHECK_MODULES(Y2CORE, yast2-core)
-])
-
-CFLAGS="${CFLAGS} -Wall -Wformat=2 -Wmissing-prototypes"
-CXXFLAGS="${CXXFLAGS} ${Y2CORE_CFLAGS} -Wall -Wformat=2"
-
-: ${AGENT_LIBADD:='-L$(libdir) -lscr -ly2util -lycpvalues'}
-AC_SUBST(AGENT_LIBADD)
-
-AC_DISABLE_STATIC
-AC_PROG_LIBTOOL
-AM_PROG_LIBTOOL dnl for libraries
-
-dnl generate the config header
-AC_CONFIG_HEADERS([config.h]) dnl at the distribution this done
-
-AC_FUNC_ALLOCA
-AC_HEADER_STDC
-
-AC_PATH_PROG(YCPDOC, ycpdoc, false, $PATH:$devtools_ybindir)
-if test "$YCPDOC" = "false"; then
-    AC_MSG_ERROR([ycpdoc is not installed])
-fi
-AC_PATH_PROG(YCPMAKEDEP, ycpmakedep, false, $PATH:$devtools_ybindir)
-if test "$YCPMAKEDEP" = "false"; then
-    AC_MSG_ERROR([ycpmakedep is not installed])
-fi
-AC_PATH_PROG(YCPC, ycpc, false, $PATH:$bindir)
-if test "$YCPC" = "false"; then
-    AC_MSG_ERROR([ycpc is not installed])
-fi
-AC_CHECK_FILE($devtools_yast2dir/data/testsuite/Makefile.testsuite, [], [
-    AC_MSG_WARN([yast2-testsuite.rpm is not installed])
-])
-
-
-# check slp.h
-yast_found_slp=no
-AC_CHECK_HEADER([slp.h],[yast_found_slp=yes])
-if test "$yast_found_slp" = "no"; then
-    AC_MSG_ERROR([Header file slp.h is missing. Please install openslp-devel.])
-fi
-
-AC_CONFIG_FILES(Makefile agent-slp/conf/Makefile
-agent-slp/src/Makefile
-agent-slp/doc/autodocs/Makefile
-agent-slp/doc/Makefile
-agent-slp/Makefile
-doc/autodocs/Makefile
-doc/Makefile
-src/Makefile
-testsuite/Makefile)
-AC_OUTPUT
-
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/src/Makefile.am new/yast2-slp-3.0.0/src/Makefile.am
--- old/yast2-slp-2.23.0/src/Makefile.am        2013-01-22 12:09:50.000000000 
+0100
+++ new/yast2-slp-3.0.0/src/Makefile.am 2013-07-30 13:41:05.000000000 +0200
@@ -1,17 +1,11 @@
-#
-# Makefile.am for xml/module/src
-#
+# Sources for slp
 
-#
-#desktop_DATA =   \
-#    slp.desktop
-
-module_DATA =  \
-    SLP.ycp
+module_DATA = \
+  modules/SLP.rb
 
 client_DATA = \
-    slp.ycp
+  clients/slp.rb
 
-EXTRA_DIST = $(module_DATA) $(client_DATA) #$(desktop_DATA)
+EXTRA_DIST = $(module_DATA) $(client_DATA)
 
-include $(top_srcdir)/Makefile.am.common
+include $(top_srcdir)/Makefile.am.common
\ No newline at end of file
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/src/SLP.ycp new/yast2-slp-3.0.0/src/SLP.ycp
--- old/yast2-slp-2.23.0/src/SLP.ycp    2013-01-22 12:09:50.000000000 +0100
+++ new/yast2-slp-3.0.0/src/SLP.ycp     1970-01-01 01:00:00.000000000 +0100
@@ -1,222 +0,0 @@
-/**
- * File:       modules/SLP.ycp
- * Package:    SLP Browser / Agent
- * Summary:    Access to SLP Agent functions
- * Authors:    Anas Nashif <[email protected]>
- *
- * $Id$
- *
- */
-{
-
-    module "SLP";
-    textdomain "slp";
-    import "Summary";
-    import "HTML";
-
-
-    string Regd = "/etc/slp.reg.d";
-
-    /**
-      * Issue the query for services
-      * @param pcServiceType The Service Type String, including authority 
string if
-      * any, for the request, such as can be discovered using  SLPSrvTypes(). 
-      * This could be, for example "service:printer:lpr" or "service:nfs".
-      * @param pcScopeList comma separated  list of scope names to search for
-      * service types.
-      * @return list<map> List of Services
-      */
-    global define list<map> FindSrvs( string pcServiceType, string pcScopeList)
-    {
-        list<map> Srvs = (list<map>) SCR::Read(.slp.findsrvs,
-                $["pcServiceType":pcServiceType, "pcScopeList": pcScopeList] );
-        y2debug("FindSrvs: %1",  Srvs);
-        return Srvs;
-    }
-
-    /**
-      * Issues an SLP service type request for service types in the scopes
-      * indicated by the pcScopeList.
-      *
-      * If the naming authority is "*", then
-      * results are returned for all naming authorities.  If the naming
-      * authority is the empty string, i.e.  "", then the default naming
-      * authority, "IANA", is used.
-      *
-      * @param pcNamingAuthority The naming authority to search.
-      * @param pcScopeList  comma separated  list of scope names to search for
-      * service types.
-      * @return list<string> Service Types
-      */
-    global define list<string> FindSrvTypes ( string pcNamingAuthority , 
string pcScopeList)
-    {
-        list<string> Types = (list<string>) SCR::Read(.slp.findsrvtypes,
-                                $["pcNamingAuthority":pcNamingAuthority ,
-                                  "pcScopeList": pcScopeList] );
-        return Types;
-    }
-
-
-
-    /**
-      * Find attributes of a service
-      * @param pcURLOrServiceType service url or type
-      * @return list<string> attributes
-      */
-    global define list<string> FindAttrs ( string pcURLOrServiceType )
-    {
-        list<string> Attrs = (list<string>) SCR::Read(.slp.findattrs,
-                                $["pcURLOrServiceType":pcURLOrServiceType] );
-        return Attrs;
-    }
-
-    /**
-      * Find attributes of a service using a unicast query
-      * @param pcURLOrServiceType service url or type
-      * @param ip IP address of the server
-      * @return list<string> attributes
-      */
-    global define list<string> UnicastFindAttrs (
-       string pcURLOrServiceType, string ip)
-    {
-       if (ip == "") return FindAttrs (pcURLOrServiceType);
-
-        list<string> Attrs = (list<string>) SCR::Read(.slp.unicastfindattrs,
-            $[
-               "pcURLOrServiceType"    : pcURLOrServiceType,
-               "ip-address"            : ip
-           ]
-       );
-        return Attrs;
-    }
-
-    /**
-      * Find attributes (using unicast query) of a service and return a map
-      * @param pcURLOrServiceType service url or type
-      * @param ip IP address of the server
-      * @return map<string,string> attributes
-      */
-    global define map<string,string> GetUnicastAttrMap (
-       string pcURLOrServiceType, string ip)
-    {
-        list<string> Attrs = UnicastFindAttrs (pcURLOrServiceType, ip);
-        return (map<string, string>) listmap(string a, Attrs, {
-            string s = substring(a, 1, size(a) - 2 );
-            list aa = splitstring(s, "=");
-            return $[  aa[0]:"empty" : aa[1]:"empty"   ];
-        });
-    }
-
-    /**
-      * Find attributes of a service and return a map
-      * @param pcURLOrServiceType service url or type
-      * @return map<string,string> attributes
-      */
-    global define map<string,string> GetAttrMap(string pcURLOrServiceType)
-    {
-
-            list<string> Attrs = FindAttrs (pcURLOrServiceType);
-            map<string, string> att = (map<string, string>)listmap(string a, 
Attrs, ``{
-                    string s = substring(a, 1, size(a) - 2 );
-                    list aa = splitstring(s, "=");
-                    return($[aa[0]:"empty":aa[1]:"empty"]);
-                    });
-            return att;
-        }
-
-    /**
-      * Attribute summary
-      * @param Attrs attribute list
-      * @return string summary
-      */
-    global define string AttrSummary (list<string> Attrs)
-    {
-       string summary = "";
-       summary = Summary::AddHeader(summary, _("Attributes"));
-       summary = Summary::OpenList      ( summary );
-       foreach(string a, Attrs, ``{
-               string s = substring(a, 1, size(a) - 2 );
-               list aa = splitstring(s, "=");
-               summary = Summary::AddListItem   ( summary, sformat("%1: %2",
-                   HTML::Bold(aa[0]:""), aa[1]:"") );
-               });
-
-       summary = Summary::CloseList     ( summary );
-       return summary;
-    }
-
-    /**
-      * Register service with SLP
-      * @param service Service to be registered
-      * @return boolean True on success
-      */
-    global define boolean Reg(string service)
-    {
-        boolean ret = (boolean)SCR::Execute(.slp.reg, service);
-        return ret;
-    }
-
-    /**
-      * Deregister service with SLP
-      * @param service Service to be deregistered
-      * @return boolean True on success
-      */
-    global define boolean DeReg(string service)
-    {
-
-        boolean ret = (boolean)SCR::Execute(.slp.dereg, service);
-        return ret;
-    }
-
-    /**
-      * Register service with SLP using a reg file
-      * @param service The service to be registered
-      * @param attr Attributes
-      * @param regfile Reg File
-      * @return boolean True on Success
-      */
-    global define boolean RegFile(string service, map<string,string> attr, 
string regfile)
-    {
-        list<string> slp = [];
-        slp=add(slp, service);
-        foreach(string k, string v , attr, ``{
-                slp=add(slp, sformat("%1=%2", tolower(k), v ));
-                });
-
-        string all = mergestring(slp, "\n");
-        SCR::Execute(.target.mkdir, Regd );
-        boolean ret =(boolean) SCR::Write(.target.string,    sformat("%1/%2", 
Regd, regfile), all);
-        return ret;
-    }
-
-    /**
-      * De-Register service with SLP by removing the reg file
-      * @param regfile The service to be deregistered
-      * @return boolean True on success
-      */
-    global define boolean DeRegFile(string regfile)
-    {
-        boolean ret = (boolean)SCR::Execute(.target.remove, regfile);
-        return ret;
-    }
-    /**
-     * Match Srv Type and return all data
-     * @param match match string
-     * @return list<map> list of services matching with all relevant data
-     */
-    global define list<map> MatchType (string match )
-    {
-        list<string> t = FindSrvTypes("*", "");
-        list<map> ret = [];
-        foreach(string type , t, {
-                if (regexpmatch(type, match)) {
-                    list<map> matched = FindSrvs(type, "");
-                    ret = (list<map>) union(ret , maplist(map m, matched, ``{
-                            m["attr"] = GetAttrMap(m["srvurl"]:"");
-                            return(m);
-                            }));
-                }
-                });
-       return ret;
-    }
-}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/src/clients/slp.rb new/yast2-slp-3.0.0/src/clients/slp.rb
--- old/yast2-slp-2.23.0/src/clients/slp.rb     1970-01-01 01:00:00.000000000 
+0100
+++ new/yast2-slp-3.0.0/src/clients/slp.rb      2013-07-30 13:41:05.000000000 
+0200
@@ -0,0 +1,202 @@
+# encoding: utf-8
+
+# File:        clients/slp.ycp
+# Package:     SLP
+# Summary:     SLP Browser
+# Authors:     Anas Nashif <[email protected]>
+#
+# $Id$
+#
+# Browse SLP services
+module Yast
+  class SlpClient < Client
+    def main
+      Yast.import "UI"
+      Yast.import "SLP"
+      textdomain "slp"
+      Yast.import "Wizard"
+      Yast.import "Label"
+
+
+      # list<map> response = SLP::FindSrvs("CIM-Object-Manager");
+      @tableItems = []
+      @treeItems = []
+
+      @contents = Top(
+        VBox(
+          Table(
+            Id(:table),
+            Opt(:notify, :immediate),
+            Header(_("Type"), _("URL"), _("Lifetime")),
+            @tableItems
+          ),
+          RichText(Id(:attr), "")
+        )
+      )
+
+      @typeResponse = SLP.FindSrvTypes("*", "")
+
+      @title = _("SLP Browser")
+      Wizard.CreateTreeDialog
+      Wizard.SetDesktopTitleAndIcon("slp")
+      @Tree = fillTree(@typeResponse)
+      Builtins.y2debug("Tree=%1", @Tree)
+      Wizard.CreateTree(@Tree, _("Service Types"))
+
+      @help = Builtins.dgettext("base", "No help available")
+      Wizard.SetContentsButtons(
+        @title,
+        @contents,
+        @help,
+        Label.BackButton,
+        Label.FinishButton
+      )
+
+      Wizard.HideAbortButton
+      Wizard.DisableBackButton
+
+
+
+      @input = nil
+      @cache = {}
+      @attrcache = {}
+      begin
+        @srvtype = ""
+        @srv = ""
+        @event = UI.WaitForEvent
+        @input = Ops.get(@event, "ID")
+        if @input == :wizardTree
+          @input = UI.QueryWidget(Id(:wizardTree), :CurrentItem)
+        end
+
+        Builtins.y2debug("input: %1", @input)
+        if Ops.is_string?(@input)
+          @srvtype = Wizard.QueryTreeItem
+        elsif @input == :table
+          @srv = Convert.to_string(UI.QueryWidget(Id(:table), :CurrentItem))
+        end
+        Builtins.y2debug("srvtype: %1", @srvtype)
+        Builtins.y2debug("srv: %1", @srv)
+        @srvsResponse = []
+        if Builtins.haskey(@cache, @srvtype)
+          @srvsResponse = Ops.get_list(@cache, @srvtype, [])
+        else
+          @srvsResponse = SLP.FindSrvs(@srvtype, "")
+          Ops.set(@cache, @srvtype, @srvsResponse)
+        end
+        @tableItems = fillTable(@srvsResponse)
+
+        @attr = []
+        @sum = ""
+
+        Builtins.foreach(@srvsResponse) do |s|
+          srvurl = Ops.get_string(s, "srvurl", "")
+          if Builtins.haskey(@attrcache, srvurl)
+            @attr = Ops.get_list(@attrcache, srvurl, [])
+          else
+            Builtins.y2debug("s: %1", s)
+            @attr = SLP.FindAttrs(srvurl)
+            Builtins.y2debug("attr: %1", @attr)
+            Ops.set(@attrcache, srvurl, @attr)
+          end
+        end
+
+        if Ops.is_string?(@input)
+          UI.ChangeWidget(Id(:table), :Items, @tableItems)
+          @srv = Ops.get_string(@srvsResponse, [0, "srvurl"], "xxx")
+          @sum = SLP.AttrSummary(Ops.get_list(@attrcache, @srv, []))
+          UI.ChangeWidget(Id(:attr), :Value, @sum)
+        elsif @input == :table
+          @sum = SLP.AttrSummary(Ops.get_list(@attrcache, @srv, []))
+          UI.ChangeWidget(Id(:attr), :Value, @sum)
+        end
+      end until @input == :next || @input == :abort || @input == :cancel
+
+      UI.CloseDialog
+      deep_copy(@input) 
+      # EOF
+    end
+
+    def createTableItem(srv)
+      srv = deep_copy(srv)
+      tabitem = Item()
+
+      srvurl = Ops.get_string(srv, "srvurl", "")
+
+      tabitem = Item(
+        Id(srvurl),
+        Builtins.substring(Ops.get_string(srv, "pcSrvType", ""), 8),
+        Builtins.substring(Ops.get_string(srv, "srvurl", ""), 8),
+        Ops.get_integer(srv, "lifetime", 0)
+      )
+      deep_copy(tabitem)
+    end
+
+    # Process Tree Items
+    def createTreeItem(_Tree, srvType, _Sub)
+      _Tree = deep_copy(_Tree)
+      _Sub = deep_copy(_Sub)
+      _Tree = Wizard.AddTreeItem(
+        _Tree,
+        "",
+        srvType,
+        Ops.add("service:", srvType)
+      )
+      _Sub = Builtins.filter(_Sub) { |s| s != "" }
+      Builtins.foreach(_Sub) do |s|
+        si = Item()
+        _Id = Ops.add(Ops.add(Ops.add("service:", srvType), ":"), s)
+        _Tree = Wizard.AddTreeItem(_Tree, Ops.add("service:", srvType), s, _Id)
+      end
+
+      deep_copy(_Tree)
+    end
+
+    def fillTable(response)
+      response = deep_copy(response)
+      items = Builtins.maplist(response) { |srv| createTableItem(srv) }
+
+      deep_copy(items)
+    end
+
+    def processTree(typeResponse)
+      typeResponse = deep_copy(typeResponse)
+      treeData = {}
+      Builtins.foreach(typeResponse) do |t|
+        tok = Builtins.splitstring(t, ":")
+        s = []
+        s = Builtins.add(s, Ops.get(tok, 2, ""))
+        t1 = Ops.get(tok, 1, "")
+        if !Builtins.haskey(treeData, t1)
+          Ops.set(treeData, t1, s)
+        else
+          old = Ops.get(treeData, t1, [])
+          Ops.set(
+            treeData,
+            t1,
+            Convert.convert(
+              Builtins.union(s, old),
+              :from => "list",
+              :to   => "list <string>"
+            )
+          )
+        end
+      end
+      deep_copy(treeData)
+    end
+
+
+    def fillTree(typeResponse)
+      typeResponse = deep_copy(typeResponse)
+      _Tree = []
+      data = processTree(typeResponse)
+      Builtins.foreach(data) do |type, sub|
+        _Tree = createTreeItem(_Tree, type, sub)
+      end
+
+      deep_copy(_Tree)
+    end
+  end
+end
+
+Yast::SlpClient.new.main
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/src/modules/SLP.rb new/yast2-slp-3.0.0/src/modules/SLP.rb
--- old/yast2-slp-2.23.0/src/modules/SLP.rb     1970-01-01 01:00:00.000000000 
+0100
+++ new/yast2-slp-3.0.0/src/modules/SLP.rb      2013-07-30 13:41:05.000000000 
+0200
@@ -0,0 +1,245 @@
+# encoding: utf-8
+
+# File:        modules/SLP.ycp
+# Package:     SLP Browser / Agent
+# Summary:     Access to SLP Agent functions
+# Authors:     Anas Nashif <[email protected]>
+#
+# $Id$
+#
+require "yast"
+
+module Yast
+  class SLPClass < Module
+    def main
+      textdomain "slp"
+      Yast.import "Summary"
+      Yast.import "HTML"
+
+
+      @Regd = "/etc/slp.reg.d"
+    end
+
+    # Issue the query for services
+    # @param [String] pcServiceType The Service Type String, including 
authority string if
+    # any, for the request, such as can be discovered using  SLPSrvTypes().
+    # This could be, for example "service:printer:lpr" or "service:nfs".
+    # @param [String] pcScopeList comma separated  list of scope names to 
search for
+    # service types.
+    # @return [Array<Hash>] List of Services
+    def FindSrvs(pcServiceType, pcScopeList)
+      _Srvs = Convert.convert(
+        SCR.Read(
+          path(".slp.findsrvs"),
+          { "pcServiceType" => pcServiceType, "pcScopeList" => pcScopeList }
+        ),
+        :from => "any",
+        :to   => "list <map>"
+      )
+      Builtins.y2debug("FindSrvs: %1", _Srvs)
+      deep_copy(_Srvs)
+    end
+
+    # Issues an SLP service type request for service types in the scopes
+    # indicated by the pcScopeList.
+    #
+    # If the naming authority is "*", then
+    # results are returned for all naming authorities.  If the naming
+    # authority is the empty string, i.e.  "", then the default naming
+    # authority, "IANA", is used.
+    #
+    # @param [String] pcNamingAuthority The naming authority to search.
+    # @param [String] pcScopeList  comma separated  list of scope names to 
search for
+    # service types.
+    # @return [Array<String>] Service Types
+    def FindSrvTypes(pcNamingAuthority, pcScopeList)
+      _Types = Convert.convert(
+        SCR.Read(
+          path(".slp.findsrvtypes"),
+          {
+            "pcNamingAuthority" => pcNamingAuthority,
+            "pcScopeList"       => pcScopeList
+          }
+        ),
+        :from => "any",
+        :to   => "list <string>"
+      )
+      deep_copy(_Types)
+    end
+
+
+
+    # Find attributes of a service
+    # @param [String] pcURLOrServiceType service url or type
+    # @return [Array<String>] attributes
+    def FindAttrs(pcURLOrServiceType)
+      _Attrs = Convert.convert(
+        SCR.Read(
+          path(".slp.findattrs"),
+          { "pcURLOrServiceType" => pcURLOrServiceType }
+        ),
+        :from => "any",
+        :to   => "list <string>"
+      )
+      deep_copy(_Attrs)
+    end
+
+
+    # Find attributes of a service using a unicast query
+    # @param [String] pcURLOrServiceType service url or type
+    # @param [String] ip IP address of the server
+    # @return [Array<String>] attributes
+    def UnicastFindAttrs(pcURLOrServiceType, ip)
+      return FindAttrs(pcURLOrServiceType) if ip == ""
+
+      _Attrs = Convert.convert(
+        SCR.Read(
+          path(".slp.unicastfindattrs"),
+          { "pcURLOrServiceType" => pcURLOrServiceType, "ip-address" => ip }
+        ),
+        :from => "any",
+        :to   => "list <string>"
+      )
+      deep_copy(_Attrs)
+    end
+
+
+    # Find attributes (using unicast query) of a service and return a map
+    # @param [String] pcURLOrServiceType service url or type
+    # @param [String] ip IP address of the server
+    # @return [Hash{String => String}] attributes
+    def GetUnicastAttrMap(pcURLOrServiceType, ip)
+      _Attrs = UnicastFindAttrs(pcURLOrServiceType, ip)
+      Builtins.listmap(_Attrs) do |a|
+        s = Builtins.substring(a, 1, Ops.subtract(Builtins.size(a), 2))
+        aa = Builtins.splitstring(s, "=")
+        { Ops.get_string(aa, 0, "empty") => Ops.get_string(aa, 1, "empty") }
+      end
+    end
+
+    # Find attributes of a service and return a map
+    # @param [String] pcURLOrServiceType service url or type
+    # @return [Hash{String => String}] attributes
+    def GetAttrMap(pcURLOrServiceType)
+      _Attrs = FindAttrs(pcURLOrServiceType)
+      att = Builtins.listmap(_Attrs) do |a|
+        s = Builtins.substring(a, 1, Ops.subtract(Builtins.size(a), 2))
+        aa = Builtins.splitstring(s, "=")
+        { Ops.get_string(aa, 0, "empty") => Ops.get_string(aa, 1, "empty") }
+      end
+      deep_copy(att)
+    end
+
+    # Attribute summary
+    # @param [Array<String>] Attrs attribute list
+    # @return [String] summary
+    def AttrSummary(_Attrs)
+      _Attrs = deep_copy(_Attrs)
+      summary = ""
+      summary = Summary.AddHeader(summary, _("Attributes"))
+      summary = Summary.OpenList(summary)
+      Builtins.foreach(_Attrs) do |a|
+        s = Builtins.substring(a, 1, Ops.subtract(Builtins.size(a), 2))
+        aa = Builtins.splitstring(s, "=")
+        summary = Summary.AddListItem(
+          summary,
+          Builtins.sformat(
+            "%1: %2",
+            HTML.Bold(Ops.get_string(aa, 0, "")),
+            Ops.get_string(aa, 1, "")
+          )
+        )
+      end
+
+      summary = Summary.CloseList(summary)
+      summary
+    end
+
+    # Register service with SLP
+    # @param [String] service Service to be registered
+    # @return [Boolean] True on success
+    def Reg(service)
+      ret = Convert.to_boolean(SCR.Execute(path(".slp.reg"), service))
+      ret
+    end
+
+    # Deregister service with SLP
+    # @param [String] service Service to be deregistered
+    # @return [Boolean] True on success
+    def DeReg(service)
+      ret = Convert.to_boolean(SCR.Execute(path(".slp.dereg"), service))
+      ret
+    end
+
+    # Register service with SLP using a reg file
+    # @param [String] service The service to be registered
+    # @param [Hash{String => String}] attr Attributes
+    # @param [String] regfile Reg File
+    # @return [Boolean] True on Success
+    def RegFile(service, attr, regfile)
+      attr = deep_copy(attr)
+      slp = []
+      slp = Builtins.add(slp, service)
+      Builtins.foreach(attr) do |k, v|
+        slp = Builtins.add(
+          slp,
+          Builtins.sformat("%1=%2", Builtins.tolower(k), v)
+        )
+      end
+
+      all = Builtins.mergestring(slp, "\n")
+      SCR.Execute(path(".target.mkdir"), @Regd)
+      ret = SCR.Write(
+        path(".target.string"),
+        Builtins.sformat("%1/%2", @Regd, regfile),
+        all
+      )
+      ret
+    end
+
+    # De-Register service with SLP by removing the reg file
+    # @param [String] regfile The service to be deregistered
+    # @return [Boolean] True on success
+    def DeRegFile(regfile)
+      ret = Convert.to_boolean(SCR.Execute(path(".target.remove"), regfile))
+      ret
+    end
+    # Match Srv Type and return all data
+    # @param [String] match match string
+    # @return [Array<Hash>] list of services matching with all relevant data
+    def MatchType(match)
+      t = FindSrvTypes("*", "")
+      ret = []
+      Builtins.foreach(t) do |type|
+        if Builtins.regexpmatch(type, match)
+          matched = FindSrvs(type, "")
+          ret = Convert.convert(
+            Builtins.union(ret, Builtins.maplist(matched) do |m|
+              Ops.set(m, "attr", GetAttrMap(Ops.get_string(m, "srvurl", "")))
+              deep_copy(m)
+            end),
+            :from => "list",
+            :to   => "list <map>"
+          )
+        end
+      end
+      deep_copy(ret)
+    end
+
+    publish :function => :FindSrvs, :type => "list <map> (string, string)"
+    publish :function => :FindSrvTypes, :type => "list <string> (string, 
string)"
+    publish :function => :FindAttrs, :type => "list <string> (string)"
+    publish :function => :UnicastFindAttrs, :type => "list <string> (string, 
string)"
+    publish :function => :GetUnicastAttrMap, :type => "map <string, string> 
(string, string)"
+    publish :function => :GetAttrMap, :type => "map <string, string> (string)"
+    publish :function => :AttrSummary, :type => "string (list <string>)"
+    publish :function => :Reg, :type => "boolean (string)"
+    publish :function => :DeReg, :type => "boolean (string)"
+    publish :function => :RegFile, :type => "boolean (string, map <string, 
string>, string)"
+    publish :function => :DeRegFile, :type => "boolean (string)"
+    publish :function => :MatchType, :type => "list <map> (string)"
+  end
+
+  SLP = SLPClass.new
+  SLP.main
+end
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' --exclude Makefile.in --exclude configure --exclude 
config.guess --exclude '*.pot' --exclude mkinstalldirs --exclude aclocal.m4 
--exclude config.sub --exclude depcomp --exclude install-sh --exclude ltmain.sh 
old/yast2-slp-2.23.0/src/slp.ycp new/yast2-slp-3.0.0/src/slp.ycp
--- old/yast2-slp-2.23.0/src/slp.ycp    2013-01-22 12:09:50.000000000 +0100
+++ new/yast2-slp-3.0.0/src/slp.ycp     1970-01-01 01:00:00.000000000 +0100
@@ -1,193 +0,0 @@
-/**
- * File:       clients/slp.ycp
- * Package:    SLP
- * Summary:    SLP Browser
- * Authors:    Anas Nashif <[email protected]>
- *
- * $Id$
- *
- * Browse SLP services
- */
-{
-    import "SLP";
-    textdomain "slp";
-    import "Wizard";
-    import "Label";
-
-    define term createTableItem(map srv) ``{
-
-        term tabitem = `item();
-
-        string srvurl = srv["srvurl"]:"";
-
-        tabitem = `item(
-                `id( srvurl),
-                substring(srv["pcSrvType"]:"", 8 ),
-                substring(srv["srvurl"]:"", 8 ),
-                srv["lifetime"]:0
-                );
-        return tabitem;
-    }
-
-    /**
-     * Process Tree Items
-     */
-    define list<map> createTreeItem(list<map> Tree, string srvType, 
list<string> Sub) ``{
-
-
-        Tree = Wizard::AddTreeItem(Tree, "", srvType, "service:" + srvType );
-        Sub = filter(string s, Sub, ``(s!=""));
-        foreach(string s, Sub, ``{
-                term si = `item();
-                string Id = "service:" + srvType + ":" + s;
-                Tree =Wizard::AddTreeItem(Tree, "service:" + srvType, s , Id);
-                });
-
-        return Tree;
-    }
-
-    define list fillTable(list<map> response) ``{
-        list items = maplist(map srv, response, ``{
-                return(createTableItem(srv));
-                });
-
-        return items;
-    }
-
-    define map<string, list<string> > processTree(list<string> typeResponse ) 
``{
-        map<string, list<string> > treeData = $[];
-        foreach(string t, typeResponse, ``{
-                list<string> tok = splitstring(t, ":");
-                list<string> s = [];
-                s=add(s, tok[2]:"" );
-                string t1 = tok[1]:"";
-                if (!haskey(treeData, t1) )
-                {
-                    treeData[t1] = s ;
-                }
-                else
-                {
-                    list old = treeData[t1]:[];
-                    treeData[t1] = (list<string>)union(s,old) ;
-                }
-                });
-        return treeData;
-    }
-
-
-    define list<map> fillTree(list<string> typeResponse) ``{
-        list<map> Tree = [];
-        map<string, list<string> > data = processTree(typeResponse);
-        foreach(string type, list<string> sub,  data, ``{
-                Tree = createTreeItem(Tree, type, sub);
-                });
-
-        return Tree;
-    }
-
-
-    /*
-    list<map> response = SLP::FindSrvs("CIM-Object-Manager");
-    */
-    list tableItems = [];
-    list treeItems = [];
-
-    term contents =
-        `Top(
-                `VBox(
-                    `Table( `id( `table ), `opt( `notify,  `immediate),
-                        `header( _("Type"), _("URL"), _("Lifetime") ),
-                        tableItems ),
-                    `RichText(`id(`attr),  "" )
-                    )
-            );
-
-    list<string> typeResponse = SLP::FindSrvTypes("*", "");
-
-    string title = _("SLP Browser");
-    Wizard::CreateTreeDialog();
-    Wizard::SetDesktopTitleAndIcon("slp");
-    list<map> Tree = fillTree(typeResponse);
-    y2debug("Tree=%1", Tree);
-    Wizard::CreateTree(Tree, _("Service Types") );
-
-    string help = dgettext("base", "No help available");
-    Wizard::SetContentsButtons(title, contents, help, Label::BackButton(),
-            Label::FinishButton());
-
-    Wizard::HideAbortButton();
-    Wizard::DisableBackButton();
-
-
-
-    any input = nil;
-    map cache = $[];
-    map attrcache = $[];
-    repeat {
-
-        string srvtype = "";
-        string srv = "";
-        map event = UI::WaitForEvent();
-        input = event["ID"]:nil;
-        if (input == `wizardTree)
-            input = UI::QueryWidget(`id(`wizardTree), `CurrentItem);
-
-        y2debug("input: %1", input);
-        if (is(input, string))
-        {
-            srvtype = Wizard::QueryTreeItem();
-        }
-        else if (input == `table )
-        {
-            srv = (string) UI::QueryWidget(`id(`table), `CurrentItem);
-        }
-        y2debug("srvtype: %1", srvtype );
-        y2debug("srv: %1", srv );
-        list<map> srvsResponse = [];
-        if(haskey(cache, srvtype))
-        {
-            srvsResponse = cache[srvtype]:[];
-        }
-        else
-        {
-            srvsResponse = SLP::FindSrvs(srvtype , "");
-            cache[srvtype] = srvsResponse;
-        }
-        tableItems = fillTable(srvsResponse);
-
-        list<string> attr = [];
-        string sum = "";
-
-        foreach(map s , srvsResponse, ``{
-                string srvurl = s["srvurl"]:"";
-                if(haskey(attrcache, srvurl))
-                {
-                attr = attrcache[srvurl]:[];
-                }
-                else
-                {
-                y2debug("s: %1", s);
-                attr = SLP::FindAttrs(srvurl);
-                y2debug("attr: %1", attr);
-                attrcache[srvurl] = attr;
-                }
-                });
-
-        if (is(input, string))
-        {
-            UI::ChangeWidget(`id(`table), `Items, tableItems);
-            srv = srvsResponse[0,"srvurl"]:"xxx";
-            sum = SLP::AttrSummary(attrcache[srv]:[]);
-            UI::ChangeWidget(`id(`attr), `Value, sum);
-        }
-        else if (input == `table )
-        {
-            sum = SLP::AttrSummary(attrcache[srv]:[]);
-            UI::ChangeWidget(`id(`attr), `Value, sum);
-        }
-    } until (input == `next || input == `abort || input == `cancel);
-
-    UI::CloseDialog();
-    return input;
-    // EOF
-}

-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to