[packages/skv] - new
qboosh
qboosh at pld-linux.org
Sun Dec 7 18:06:34 CET 2014
commit 7f51379c70ec065a6f9d9f75caec63321a07b1c8
Author: Jakub Bogusz <qboosh at pld-linux.org>
Date: Sun Dec 7 18:06:46 2014 +0100
- new
skv-link.patch | 49 ++++++++
skv.spec | 177 +++++++++++++++++++++++++++++
todonotes.sty | 354 +++++++++++++++++++++++++++++++++++++++++++++++++++++++++
3 files changed, 580 insertions(+)
---
diff --git a/skv.spec b/skv.spec
new file mode 100644
index 0000000..8d6e1f7
--- /dev/null
+++ b/skv.spec
@@ -0,0 +1,177 @@
+# TODO: use system *tex todonotes package (newer texlive?)
+#
+# Conditional build:
+%bcond_without apidocs # LaTeX documentation
+%bcond_with ibverbs # use ibverbs (OFED) instead of sockets for communication
+%bcond_with rocksdb # use rocksdb as database backend
+#
+Summary: Scalable Key/Value Store
+Summary(pl.UTF-8): Scalable Key/Value Store - skalowalna baza klucz-wartość
+Name: skv
+Version: 0.1.0
+%define snap 20141120
+%define gitrev 14cbb85
+Release: 0.%{snap}.1
+License: Eclipse Public License v1.0
+Group: Daemons
+Source0: https://github.com/Scalable-Key-Value/code/archive/%{gitrev}/%{name}-%{gitrev}.tar.gz
+# Source0-md5: 0ea9908ad80ae270238b65eca95da019
+Source1: https://github.com/Eyescale/CMake/archive/c13f465/Eyescale-CMake-c13f465.tar.gz
+# Source1-md5: 71df45dad1b0c62d6039655fe898ea26
+# generated from ftp://ftp.ctan.org/pub/tex/macros/latex2e/contrib/todonotes/
+Source2: todonotes.sty
+Patch0: %{name}-link.patch
+URL: https://github.com/Scalable-Key-Value
+%{?with_rocksdb:BuildRequires: bzip2-devel}
+BuildRequires: cmake >= 2.8
+%{?with_ibverbs:BuildRequires: librdmacm-devel}
+BuildRequires: libstdc++-devel
+BuildRequires: mpi-devel
+%{?with_rocksdb:BuildRequires: rocksdb-devel}
+%{?with_apidocs:BuildRequires: texlive-format-pdflatex}
+%{?with_apidocs:BuildRequires: texlive-latex-pgf}
+%{?with_apidocs:BuildRequires: texlive-tex-xkeyval}
+%{?with_rocksdb:BuildRequires: zlib-devel}
+Requires: %{name}-libs = %{version}-%{release}
+BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
+
+%description
+SKV (Scalable Key-Value Store) is a parallel client, parallel server,
+key-value database system with basic function similar to BDB. SKV
+storage can be drawn from main memory of the node of the parallel
+machine or from a single-node key/value store that serves as a storage
+back-end for the distributed SKV.
+
+%description -l pl.UTF-8
+SKV (Scalable Key-Value Store - skalowalna baza klucz-wartość) to
+system baz danych klucz-wartość z równoległym klientem i równoległym
+serwerem o funkcjonalności zbliżonej do BDB. Dane SKV można pobierać z
+pamięci głównej węzła maszyny równoległej lub z danych klucz-wartość
+pojedynczego węzła, służących jako backend dla rozproszonego SKV.
+
+%package libs
+Summary: Shared SKV libraries
+Summary(pl.UTF-8): Biblioteki współdzielone SKV
+Group: Libraries
+
+%description libs
+Shared SKV libraries.
+
+%description libs -l pl.UTF-8
+Biblioteki współdzielone SKV.
+
+%package devel
+Summary: Header files for SKV library
+Summary(pl.UTF-8): Pliki nagłówkowe biblioteki SKV
+Group: Development/Libraries
+Requires: %{name}-libs = %{version}-%{release}
+Requires: libstdc++-devel
+
+%description devel
+Header files for SKV library.
+
+%description devel -l pl.UTF-8
+Pliki nagłówkowe biblioteki SKV.
+
+%package apidocs
+Summary: SKV API documentation
+Summary(pl.UTF-8): Dokumentacja API biblioteki SKV
+Group: Documentation
+
+%description apidocs
+API documentation for SKV library.
+
+%description apidocs -l pl.UTF-8
+Dokumentacja API biblioteki SKV.
+
+%prep
+%setup -q -a1 -n code-14cbb85f056ae8eecb6936f1613233940dbf7963
+%patch0 -p1
+
+%{__mv} CMake-* CMake/common
+%{__rm} .gitexternals
+
+cp -p %{SOURCE2} doc/todonotes.sty
+
+%build
+install -d build
+cd build
+%cmake .. \
+ -DBUILDYARD_DISABLED=ON \
+ -DCOMMON_LIBRARY_TYPE=SHARED \
+ %{?with_ibverbs:-DSKV_COMM_API_TYPE=verbs} \
+%ifarch %{ix86} %{x8664}
+ -DSKV_ENV=x86 \
+%endif
+%ifarch ppc ppc64
+ -DSKV_ENV=BGAS \
+%endif
+ %{?with_rocksdb:-DSKV_LOCAL_KV_BACKEND=rocksdb}
+
+%{__make}
+cd ..
+
+%if %{with apidocs}
+%{__make} -C doc
+%endif
+
+%install
+rm -rf $RPM_BUILD_ROOT
+
+%{__make} -C build install \
+ DESTDIR=$RPM_BUILD_ROOT
+
+%{__mv} $RPM_BUILD_ROOT%{_prefix}/etc $RPM_BUILD_ROOT
+
+%clean
+rm -rf $RPM_BUILD_ROOT
+
+%post -p /sbin/ldconfig
+%postun -p /sbin/ldconfig
+
+%files
+%defattr(644,root,root,755)
+%doc CHANGELOG LICENSE.txt README
+%attr(755,root,root) %{_bindir}/SKVServer
+%attr(755,root,root) %{_bindir}/skv_base_test
+%attr(755,root,root) %{_bindir}/skv_bench
+%attr(755,root,root) %{_bindir}/skv_test_bulk
+%attr(755,root,root) %{_bindir}/skv_test_insert_retrieve_async
+%attr(755,root,root) %{_bindir}/skv_test_insert_retrieve_sync
+%attr(755,root,root) %{_bindir}/test_skv_insert_command
+%attr(755,root,root) %{_bindir}/test_skv_remove_command
+%attr(755,root,root) %{_libdir}/libfxlogger.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libfxlogger.so.1
+%attr(755,root,root) %{_libdir}/libit_api.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libit_api.so.1
+%attr(755,root,root) %{_libdir}/libskv_client.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libskv_client.so.1
+%attr(755,root,root) %{_libdir}/libskv_client_mpi.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libskv_client_mpi.so.1
+%attr(755,root,root) %{_libdir}/libskv_common.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libskv_common.so.1
+%attr(755,root,root) %{_libdir}/libskvc.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libskvc.so.1
+%attr(755,root,root) %{_libdir}/libskvc_mpi.so.*.*.*
+%attr(755,root,root) %ghost %{_libdir}/libskvc_mpi.so.1
+%config(noreplace) %verify(not md5 mtime size) %{_sysconfdir}/skv_server.conf
+
+%files devel
+%defattr(644,root,root,755)
+%attr(755,root,root) %{_libdir}/libfxlogger.so
+%attr(755,root,root) %{_libdir}/libit_api.so
+%attr(755,root,root) %{_libdir}/libskv_client.so
+%attr(755,root,root) %{_libdir}/libskv_client_mpi.so
+%attr(755,root,root) %{_libdir}/libskv_common.so
+%attr(755,root,root) %{_libdir}/libskvc.so
+%attr(755,root,root) %{_libdir}/libskvc_mpi.so
+%{_includedir}/skv
+%{_pkgconfigdir}/skv.pc
+%dir %{_datadir}/skv
+%{_datadir}/skv/CMake
+
+%if %{with apidocs}
+%files apidocs
+%defattr(644,root,root,755)
+%doc doc/skvdoc.pdf
+%endif
diff --git a/skv-link.patch b/skv-link.patch
new file mode 100644
index 0000000..1ec49c7
--- /dev/null
+++ b/skv-link.patch
@@ -0,0 +1,49 @@
+--- code-14cbb85f056ae8eecb6936f1613233940dbf7963/CMakeLists.txt.orig 2014-11-20 00:12:07.000000000 +0100
++++ code-14cbb85f056ae8eecb6936f1613233940dbf7963/CMakeLists.txt 2014-12-07 16:44:01.286219809 +0100
+@@ -83,7 +83,7 @@
+
+ if(SKV_COMM_API_TYPE MATCHES "verbs")
+ find_package(OFED REQUIRED)
+- set( IT_API_LIBS ${OFED_LIBRARIES} pthread rt )
++ set( IT_API_LIBS ${OFED_LIBRARIES} pthread rt fxlogger )
+ add_definitions(
+ # enable workaround for missing RoQ loopback functionality
+ -DSKV_ROQ_LOOPBACK_WORKAROUND
+@@ -93,7 +93,7 @@
+ DESTINATION ${CMAKE_MODULE_INSTALL_PATH})
+ endif()
+ if(SKV_COMM_API_TYPE MATCHES "sockets")
+- set( IT_API_LIBS pthread rt )
++ set( IT_API_LIBS pthread rt fxlogger )
+ endif()
+
+
+--- code-14cbb85f056ae8eecb6936f1613233940dbf7963/skv/CMakeLists.txt.orig 2014-11-20 00:12:07.000000000 +0100
++++ code-14cbb85f056ae8eecb6936f1613233940dbf7963/skv/CMakeLists.txt 2014-12-07 16:46:51.636212660 +0100
+@@ -1,7 +1,9 @@
+
+ set(SKVC_SOURCES c/skv.cpp)
+ set(SKVC_PUBLIC_HEADERS c/skv.h)
++set(SKVC_LINK_LIBRARIES skv_client fxlogger)
+ set(SKVC_MPI_SOURCES ${SKVC_SOURCES})
++set(SKVC_MPI_LINK_LIBRARIES skv_client_mpi fxlogger)
+
+ set(SKV_COMMON_SOURCES
+ common/skv_config.cpp
+@@ -21,6 +23,7 @@
+ common/skv_types_ext.hpp
+ common/skv_mutex.hpp
+ )
++set(SKV_COMMON_LINK_LIBRARIES fxlogger)
+
+ set(SKV_CLIENT_SOURCES
+ client/skv_client.cpp
+@@ -54,7 +57,7 @@
+ set(SKV_CLIENT_LINK_LIBRARIES it_api fxlogger skv_common)
+
+ set(SKV_CLIENT_MPI_SOURCES ${SKV_CLIENT_SOURCES})
+-set(SKV_CLIENT_MPI_LINK_LIBRARIES ${SKV_CLIENT_LINK_LIBRARIES})
++set(SKV_CLIENT_MPI_LINK_LIBRARIES ${SKV_CLIENT_LINK_LIBRARIES} ${MPI_LIBRARIES})
+
+ set(SKVSERVER_SOURCES
+ server/skv_local_kv_${SKV_LOCAL_KV_BACKEND}.cpp
diff --git a/todonotes.sty b/todonotes.sty
new file mode 100644
index 0000000..27d2319
--- /dev/null
+++ b/todonotes.sty
@@ -0,0 +1,354 @@
+%%
+%% This is file `todonotes.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% todonotes.dtx (with options: `package')
+%%
+%% This is a generated file.
+%%
+%% Copyright (C) 2008 by Henrik Skov Midtiby <henrikmidtiby at gmail.com>
+%%
+%% This file may be distributed and/or modified under the conditions of
+%% the LaTeX Project Public License, either version 1.2 of this license
+%% or (at your option) any later version. The latest version of this
+%% license is in:
+%%
+%% http://www.latex-project.org/lppl.txt
+%%
+%% and version 1.2 or later is part of all distributions of LaTeX version
+%% 1999/12/01 or later.
+%%
+\NeedsTeXFormat{LaTeX2e}[1999/12/01]
+\ProvidesPackage{todonotes}
+ [2009/12/25 .dtx Todonotes source and documentation.]
+
+\ProvidesPackage{todonotes}[2009/04/02]
+\RequirePackage{ifthen}
+\RequirePackage{xkeyval}
+\RequirePackage{xcolor}
+\RequirePackage{tikz}
+\RequirePackage{calc}
+\newcommand{\@todonotes at text}{}%
+\newcommand{\@todonotes at backgroundcolor}{orange}
+\newcommand{\@todonotes at linecolor}{orange}
+\newcommand{\@todonotes at bordercolor}{black}
+\newcommand{\@todonotes at textwidth}{\marginparwidth}
+\newcommand{\@todonotes at textsize}{\normalsize}
+\newcommand{\@todonotes at figwidth}{\columnwidth}
+\AtBeginDocument{
+\ifx\undefined\phantomsection
+\newcommand{\phantomsection}{}
+\fi
+}
+
+\newcommand{\@todonotes at todolistname}{Todo list}
+\newcommand{\@todonotes at MissingFigureText}{Figure}
+\newcommand{\@todonotes at MissingFigureUp}{Missing}
+\newcommand{\@todonotes at MissingFigureDown}{figure}
+\newcommand{\@todonotes at SetTodoListName}[1]
+ {\renewcommand{\@todonotes at todolistname}{#1}}
+\newcommand{\@todonotes at SetMissingFigureText}[1]
+ {\renewcommand{\@todonotes at MissingFigureText}{#1}}
+\newcommand{\@todonotes at SetMissingFigureUp}[1]
+ {\renewcommand{\@todonotes at MissingFigureUp}{#1}}
+\newcommand{\@todonotes at SetMissingFigureDown}[1]
+ {\renewcommand{\@todonotes at MissingFigureDown}{#1}}
+\newif{\if at todonotes@reverseMissingFigureTriangle}
+\DeclareOptionX{catalan}{
+ \@todonotes at SetTodoListName{Llista de feines pendents}%
+ \@todonotes at SetMissingFigureText{Figura}%
+ \@todonotes at SetMissingFigureUp{Figura}%
+ \@todonotes at SetMissingFigureDown{pendent}%
+}
+\DeclareOptionX{danish}{%
+ \@todonotes at SetTodoListName{G\o{}rem\aa{}lsliste}%
+ \@todonotes at SetMissingFigureText{Figur}%
+ \@todonotes at SetMissingFigureUp{Manglende}%
+ \@todonotes at SetMissingFigureDown{figur}%
+}
+\DeclareOptionX{dutch}{%
+ \@todonotes at SetTodoListName{Lijst van onafgewerkte taken}%
+ \@todonotes at SetMissingFigureText{Figuur}%
+ \@todonotes at SetMissingFigureUp{Ontbrekende}%
+ \@todonotes at SetMissingFigureDown{figuur}%
+}
+\DeclareOptionX{french}{%
+ \@todonotes at SetTodoListName{Liste des points \`a traiter}%
+ \@todonotes at SetMissingFigureText{Figure}%
+ \@todonotes at SetMissingFigureUp{Figure}%
+ \@todonotes at SetMissingFigureDown{manquante}%
+ \@todonotes at reverseMissingFigureTrianglefalse
+}
+\DeclareOptionX{german}{%
+ \@todonotes at SetTodoListName{Liste der noch zu erledigenden Punkte}%
+ \@todonotes at SetMissingFigureText{Abbildung}%
+ \@todonotes at SetMissingFigureUp{Fehlende}%
+ \@todonotes at SetMissingFigureDown{Abbildung}%
+}
+\DeclareOptionX{italian}{
+ \@todonotes at SetTodoListName{Elenco delle cose da fare}%
+ \@todonotes at SetMissingFigureText{Figura}%
+ \@todonotes at SetMissingFigureUp{Figura}%
+ \@todonotes at SetMissingFigureDown{mancante}%
+}
+\DeclareOptionX{ngerman}{%
+ \@todonotes at SetTodoListName{Liste der noch zu erledigenden Punkte}%
+ \@todonotes at SetMissingFigureText{Abbildung}%
+ \@todonotes at SetMissingFigureUp{Fehlende}%
+ \@todonotes at SetMissingFigureDown{Abbildung}%
+}
+\DeclareOptionX{portuguese}{
+ \@todonotes at SetTodoListName{Lista de tarefas pendentes}%
+ \@todonotes at SetMissingFigureText{Figura}%
+ \@todonotes at SetMissingFigureUp{Figura}%
+ \@todonotes at SetMissingFigureDown{pendente}%
+}
+\DeclareOptionX{spanish}{
+ \@todonotes at SetTodoListName{Lista de tareas pendientes}%
+ \@todonotes at SetMissingFigureText{Figura}%
+ \@todonotes at SetMissingFigureUp{Figura}%
+ \@todonotes at SetMissingFigureDown{pendient}%
+}
+\newcounter{@todonotes at numberoftodonotes}
+\newif{\if at todonotes@obeyDraft}
+\DeclareOptionX{obeyDraft}{\@todonotes at obeyDrafttrue}
+\newif{\if at todonotes@isDraft}
+\DeclareOptionX{draft}{\@todonotes at isDrafttrue}
+\newif{\if at todonotes@disabled}
+\DeclareOptionX{disable}{\@todonotes at disabledtrue}
+\newif{\if at todonotes@colorinlistoftodos}
+\DeclareOptionX{colorinlistoftodos}{\@todonotes at colorinlistoftodostrue}
+\newif{\if at todonotes@dviStyle}
+\DeclareOptionX{dvistyle}{\@todonotes at dviStyletrue}
+\define at key{todonotes.sty}%
+ {color}{
+ \renewcommand{\@todonotes at backgroundcolor}{#1}
+ \renewcommand{\@todonotes at linecolor}{#1}}
+\define at key{todonotes.sty}%
+ {backgroundcolor}{\renewcommand{\@todonotes at backgroundcolor}{#1}}
+\define at key{todonotes.sty}%
+ {linecolor}{\renewcommand{\@todonotes at linecolor}{#1}}
+\define at key{todonotes.sty}%
+ {bordercolor}{\renewcommand{\@todonotes at bordercolor}{#1}}
+\newif{\if at todonotes@prependcaptionglobal}
+\@todonotes at prependcaptionglobalfalse
+\DeclareOptionX{prependcaption}{\@todonotes at prependcaptionglobaltrue}
+\define at key{todonotes.sty}%
+ {textwidth}{\renewcommand{\@todonotes at textwidth}{#1}}
+\define at key{todonotes.sty}%
+ {textsize}{\renewcommand{\@todonotes at textsize}{\csname #1\endcsname}}
+\newif{\if at todonotes@shadowenabled}
+\@todonotes at shadowenabledfalse
+\DeclareOptionX{shadow}{\@todonotes at shadowenabledtrue
+\usetikzlibrary{shadows}}
+\define at key{todonotes.sty}%
+ {figwidth}{\renewcommand{\@todonotes at figwidth}{#1}}
+\ProcessOptionsX*
+\if at todonotes@disabled
+\else
+\if at todonotes@obeyDraft
+\@todonotes at disabledtrue
+\if at todonotes@isDraft
+\@todonotes at disabledfalse
+\fi
+\fi
+\fi
+
+\newcommand{\@todonotes at currentlinecolor}{}%
+\newcommand{\@todonotes at currentbackgroundcolor}{}%
+\newcommand{\@todonotes at currentbordercolor}{}%
+\define at key{todonotes}{color}{%
+ \renewcommand{\@todonotes at currentlinecolor}{#1}%
+ \renewcommand{\@todonotes at currentbackgroundcolor}{#1}}%
+\define at key{todonotes}{linecolor}{%
+ \renewcommand{\@todonotes at currentlinecolor}{#1}}%
+\define at key{todonotes}{backgroundcolor}{%
+ \renewcommand{\@todonotes at currentbackgroundcolor}{#1}}%
+\define at key{todonotes}{bordercolor}{%
+ \renewcommand{\@todonotes at currentbordercolor}{#1}}%
+\newcommand{\@todonotes at sizecommand}{}%
+\define at key{todonotes}{size}{\renewcommand{\@todonotes at sizecommand}{#1}}%
+\newif\if at todonotes@appendtolistoftodos%
+\define at key{todonotes}{list}[]{\@todonotes at appendtolistoftodostrue}%
+\define at key{todonotes}{nolist}[]{\@todonotes at appendtolistoftodosfalse}%
+\newif\if at todonotes@inlinenote%
+\define at key{todonotes}{inline}[]{\@todonotes at inlinenotetrue}%
+\define at key{todonotes}{noinline}[]{\@todonotes at inlinenotefalse}%
+\newif\if at todonotes@prependcaption%
+\define at key{todonotes}{prepend}[]{\@todonotes at prependcaptiontrue}%
+\define at key{todonotes}{noprepend}[]{\@todonotes at prependcaptionfalse}%
+\newif\if at todonotes@line%
+\define at key{todonotes}{line}[]{\@todonotes at linetrue}%
+\define at key{todonotes}{noline}[]{\@todonotes at linefalse}%
+\newcommand{\@todonotes at caption}{}%
+\newif\if at todonotes@captiongiven%
+\define at key{todonotes}{caption}%
+ {\renewcommand{\@todonotes at caption}{#1}%
+ \@todonotes at captiongiventrue}%
+\define at key{todonotes}{nocaption}[]{\@todonotes at captiongivenfalse}%
+\newcommand{\@todonotes at currentfigwidth}{\@todonotes at figwidth}
+\define at key{todonotes}%
+ {figwidth}{\renewcommand{\@todonotes at currentfigwidth}{#1}}
+\presetkeys%
+ {todonotes}%
+ {linecolor=\@todonotes at linecolor,%
+ backgroundcolor=\@todonotes at backgroundcolor,%
+ bordercolor=\@todonotes at bordercolor,%
+ noinline,%
+ nocaption,%
+ figwidth=\@todonotes at figwidth,%
+ line, list, size=\@todonotes at textsize}{}%
+\if at todonotes@disabled%
+ \newcommand{\listoftodos}[1][]{}
+ \newcommand{\todo}[2][]{\ignorespaces}
+ \newcommand{\missingfigure}[2][]{}
+\else % \if at todonotes@disabled
+\newcommand{\listoftodos}[1][\@todonotes at todolistname]
+ {\section*{#1} \@starttoc{tdo}}
+\newcommand{\l at todo}
+ {\@dottedtocline{1}{0em}{2.3em}}
+\tikzstyle{notestyleraw} = [
+ draw=\@todonotes at currentbordercolor,
+ fill=\@todonotes at currentbackgroundcolor,
+ line width=0.5pt,
+ text width = \@todonotes at textwidth - 1.6 ex - 1pt,
+ inner sep = 0.8 ex,
+ rounded corners=4pt]
+\if at todonotes@shadowenabled
+\tikzstyle{notestyle} = [notestyleraw,
+ general shadow={shadow xshift=.5ex, shadow yshift=-.5ex,
+ opacity=1,fill=black!50}]
+\else
+\tikzstyle{notestyle} = [notestyleraw]
+\fi
+\tikzstyle{notestyleleft} = [
+ notestyle,
+ left]
+\tikzstyle{connectstyle} = [
+ thick,
+ draw=\@todonotes at currentlinecolor]
+\tikzstyle{inlinenotestyle} = [
+ notestyle,
+ text width=\linewidth - 1.6 ex - 1 pt]
+\newcommand{\todo}[2][]{%
+\if at todonotes@prependcaptionglobal%
+\@todonotes at prependcaptiontrue%
+\else%
+\@todonotes at prependcaptionfalse%
+\fi%
+\renewcommand{\@todonotes at text}{#2}%
+\renewcommand{\@todonotes at caption}{#2}%
+\setkeys{todonotes}{#1}%
+\addtocounter{@todonotes at numberoftodonotes}{1}%
+\if at todonotes@appendtolistoftodos%
+ \phantomsection%
+ \if at todonotes@captiongiven%
+ \else%
+ \renewcommand{\@todonotes at caption}{#2}%
+ \fi%
+ \if at todonotes@colorinlistoftodos%
+ \addcontentsline{tdo}{todo}{\protect{%
+ \colorbox{\@todonotes at currentbackgroundcolor}%
+ {\textcolor{\@todonotes at currentbackgroundcolor}{o}}%
+ \ \@todonotes at caption}}%
+ \else%
+ \addcontentsline{tdo}{todo}{\protect{\@todonotes at caption}}%
+ \fi%
+\fi%
+\if at todonotes@captiongiven%
+ \if at todonotes@prependcaption%
+ \renewcommand{\@todonotes at text}{\@todonotes at caption: #2}%
+ \fi%
+\fi%
+\if at todonotes@inlinenote%
+ \if at todonotes@dviStyle%
+ {\par\noindent\begin{tikzpicture}[remember picture]%
+ \draw node[inlinenotestyle] {};\end{tikzpicture}\par}%
+ {\noindent \@todonotes at sizecommand \@todonotes at text}%
+ {\par\noindent\begin{tikzpicture}[remember picture]%
+ \draw node[inlinenotestyle] {};\end{tikzpicture}\par}%
+ \else%
+ {\par\noindent\begin{tikzpicture}[remember picture]%
+ \draw node[inlinenotestyle] {\@todonotes at sizecommand \@todonotes at text};%
+ \end{tikzpicture}\par}%
+ \fi%
+\else%
+\begin{tikzpicture}[remember picture, baseline=-0.75ex]%
+ \node [coordinate] (inText) {};%
+\end{tikzpicture}%
+\marginpar[{% Draw note in left margin
+\if at todonotes@dviStyle%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle] {};%
+ \end{tikzpicture}\\ %
+ \begin{minipage}{\@todonotes at textwidth}%
+ \@todonotes at sizecommand \@todonotes at text%
+ \end{minipage}\\%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle] (inNote) {};%
+ \end{tikzpicture}%
+\else%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle] (inNote)%
+ {\@todonotes at sizecommand \@todonotes at text};%
+ \end{tikzpicture}%
+\fi%
+\if at todonotes@line%
+ \begin{tikzpicture}[remember picture, overlay]%
+ \draw[connectstyle]%
+ ([yshift=-0.2cm] inText)%
+ -| ([xshift=0.2cm] inNote.east)%
+ -| (inNote.east);%
+ \end{tikzpicture}%
+\fi%
+}]{% Draw note in right margin
+\if at todonotes@dviStyle%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle] {};%
+ \end{tikzpicture}\\%
+ \begin{minipage}{\@todonotes at textwidth}%
+ \@todonotes at sizecommand \@todonotes at text%
+ \end{minipage}\\%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle] (inNote) {};%
+ \end{tikzpicture}%
+\else%
+ \begin{tikzpicture}[remember picture]%
+ \draw node[notestyle](inNote)%
+ {\@todonotes at sizecommand \@todonotes at text};%
+ \end{tikzpicture}%
+\fi%
+\if at todonotes@line%
+ \begin{tikzpicture}[remember picture, overlay]%
+ \draw[connectstyle]%
+ ([yshift=-0.2cm] inText)%
+ -| ([xshift=-0.2cm] inNote.west)%
+ -| (inNote.west);%
+ \end{tikzpicture}%
+\fi%
+}%
+\fi%
+\ignorespaces%
+}%
+\newcommand{\missingfigure}[2][]{
+\setkeys{todonotes}{#1}%
+\addcontentsline{tdo}{todo}{\@todonotes at MissingFigureText: \protect{#2}}%
+\par
+\noindent
+\begin{tikzpicture}
+\draw[fill=black!40, draw = white, line width=0pt]
+ (-2, -2.5) rectangle +(\@todonotes at currentfigwidth, 4cm);
+\draw (2, -0.3) node[right, text
+ width=\@todonotes at currentfigwidth-4.5cm] {#2};
+\draw[red, fill=white, rounded corners = 5pt, line width=10pt]
+ (30:2cm) -- (150:2cm) -- (270:2cm) -- cycle;
+\draw (0, 0.3) node {\@todonotes at MissingFigureUp};
+\draw (0, -0.3) node {\@todonotes at MissingFigureDown};
+\end{tikzpicture}
+}% Ending \missingfigure command
+\fi % Ending \@todonotes at ifdisabled
+\endinput
+%%
+%% End of file `todonotes.sty'.
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/skv.git/commitdiff/7f51379c70ec065a6f9d9f75caec63321a07b1c8
More information about the pld-cvs-commit
mailing list