orangesquid (os) wrote,
orangesquid
os

doxygen+dot

Some of doxygen's integration with graphviz [dot] requires the epstopdf package from CTAN. I made a quick little script to install it:

mkdir epstopdf
cd epstopdf
cat >url << EOF
http://mirrors.med.harvard.edu/ctan/support/epstopdf/
http://tug.org/epstopdf/
EOF
# NOTE: if you do not have ash, change /bin/ash to /bin/sh below
cat >fetch << 'EOF'
#!/bin/ash
wget -R '*\?*' -nH -nd -r -np -l0 `head -n1 url`
EOF
chmod 0755 fetch
./fetch
cat >install << 'EOF'
#!/bin/bash
echo '#!'$(which perl) >/usr/local/bin/epstopdf
cat epstopdf.pl >>/usr/local/bin/epstopdf
chown root:root /usr/local/bin/epstopdf
chmod 0755 /usr/local/bin/epstopdf
ln -sf epstopdf /usr/local/bin/repstopdf
install -o root -g root -m 0644 epstopdf.1 /usr/local/man/man1/
# if you are not on a distro that keeps program-specific docs in /usr/doc
# like slackware does, you can remove everything from here to EOF
docdir=/usr/doc/$(/usr/local/bin/epstopdf --version |
    grep ^epstopdf |
    sed '
      s/^\([^ ]\+\).*Id:.\+ \([0-9]\{4\}-[0-9]\{2\}-[0-9]\{2\}\) .\+)/\1 \2/
      s/-//g
      y/ /-/'
)
install -o root -g root -m 0755 -d "$docdir"
install -o root -g root -m 0644 README epstopdf.man1.pdf "$docdir"
EOF
chmod 0755 install
su -c ./install
cd ..

Tags: doxygen, graphviz
Subscribe
  • Post a new comment

    Error

    default userpic

    Your IP address will be recorded 

    When you submit the form an invisible reCAPTCHA check will be performed.
    You must follow the Privacy Policy and Google Terms of use.
  • 0 comments