Skip to content

Commit

Permalink
rename shogun -> modshogun for R and add some fixes
Browse files Browse the repository at this point in the history
  • Loading branch information
Soeren Sonnenburg committed Jul 28, 2013
1 parent 6076c05 commit 5812e0d
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 18 deletions.
12 changes: 2 additions & 10 deletions src/.r-install.sh
Expand Up @@ -122,18 +122,14 @@ get_hmm <- function() .External("$2","get_hmm",PACKAGE="$2")
.onLoad <- function(lib, pkg) .First.lib(lib,pkg)
.onUnload <- function(lib) .Last.lib(lib)
# a nice banner
#
.onAttach <- function(lib, pkg) cat(paste("\nWelcome! This is SHOGUN version $VERSION\n"))
EOF

# R-MODULAR
else
echo "Installing modular shogun interface for R"

cat >"$1/$2/NAMESPACE" <<EOF
export( shogun )
useDynLib(modshogun, .registration = TRUE)
EOF

cat >"$1/$2/R/$2" <<EOF
Expand All @@ -149,7 +145,7 @@ EOF

for f in *.so
do
echo "library.dynam(\"`basename $f`\", pkg, lib)" >> "$1/$2/R/$2"
echo "library.dynam(\"`basename $f .so`\", pkg, lib)" >> "$1/$2/R/$2"
done

for f in *.RData
Expand Down Expand Up @@ -178,9 +174,5 @@ cat >>"$1/$2/R/$2" <<EOF
#
.onLoad <- function(lib, pkg) .First.lib(lib,pkg)
.onUnload <- function(lib) .Last.lib(lib)
# a nice banner
#
.onAttach <- function() cat(paste("\nWelcome! This is SHOGUN version $VERSION\n"))
EOF
fi
16 changes: 8 additions & 8 deletions src/Makefile.template
Expand Up @@ -289,14 +289,14 @@ install-perl_modular: $(TEMPLATE_TARGET)
done

install-r_modular: $(TEMPLATE_TARGET)
install -d -m755 $(DESTDIR)$(RDIR)/shogun/demo
install -d -m755 $(DESTDIR)$(RDIR)/shogun/libs
install -d -m755 $(DESTDIR)$(RDIR)/shogun/Meta
install -d -m755 $(DESTDIR)$(RDIR)/shogun/R
install -m644 $(CONFIGPATH)/../examples/documented/r_modular/*.R $(DESTDIR)$(RDIR)/shogun/demo
install -m755 *.$(EXT_LIB) $(DESTDIR)$(RDIR)/shogun/libs
install -m755 *.RData $(DESTDIR)$(RDIR)/shogun/R
$(CONFIGPATH)/.r-install.sh $(DESTDIR)$(RDIR) shogun $(EXT_LIB)
install -d -m755 $(DESTDIR)$(RDIR)/modshogun/demo
install -d -m755 $(DESTDIR)$(RDIR)/modshogun/libs
install -d -m755 $(DESTDIR)$(RDIR)/modshogun/Meta
install -d -m755 $(DESTDIR)$(RDIR)/modshogun/R
install -m644 $(CONFIGPATH)/../examples/documented/r_modular/*.R $(DESTDIR)$(RDIR)/modshogun/demo
install -m755 *.$(EXT_LIB) $(DESTDIR)$(RDIR)/modshogun/libs
install -m755 *.RData $(DESTDIR)$(RDIR)/modshogun/R
$(CONFIGPATH)/.r-install.sh $(DESTDIR)$(RDIR) modshogun $(EXT_LIB) $(SAVERDS)

install-octave_modular: $(TEMPLATE_TARGET)
install -d -m755 "$(DESTDIR)$(OCTDIR)/shogun"
Expand Down

0 comments on commit 5812e0d

Please sign in to comment.