Download and Install htdig version 3.1.6 on Mac OS X
Friday the 25th of July, 2008

    htdig  most recent diff


      View the most recent changes for the htdig port at: htdig.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for htdig.
      The raw portfile for htdig 3.1.6 is located here:
      http://htdig.darwinports.com/dports/www/htdig/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/htdig
      Google
      Web Darwinports.com



      # $Id: Portfile 28545 2007-09-03 12:26:00Z mww macports.org $

      PortSystem 1.0
      Name: htdig
      Version: 3.1.6
      Category: www
      Platform: darwin freebsd
      Maintainers: simon cotsworth.com
      Description: WWW Search Engine Software

      Long Description: The ht://Dig system is a complete world wide web indexing and searching system for a domain or intranet. This system is not meant to replace the need for powerful internet-wide search systems like Lycos, Infoseek, Google and AltaVista. Instead it is meant to cover the search needs for a single company, campus, or even a particular sub section of a web site. As opposed to some WAIS-based or web-server based search engines, ht://Dig can easily span several web servers. The type of these different web servers doesn't matter as long as they understand common protocols like HTTP.

      Homepage: http://www.htdig.org/
      master_sites ${homepage}files/
      checksums md5 7a2f20d8d6149efd8d119bb2ebf55f23
      patchfiles patch-metadate.0 patch-Makefile.0 patch-documentation.1 patch-documentation.2 patch-Date-viewing.0 patch-ExternalParser-max_doc_size.0 patch-htnotifyNull.0 patch-JavaScript.0 patch-CONFIG.in

      set doc_path "${prefix}/share/doc/${name}"
      set conf_path "${prefix}/etc/${name}"
      set share_path "${prefix}/share/${name}"
      set db_path "${prefix}/var/${name}"
      set cgi_path ""
      set httpd_doc_path ""
      set httpd_conf_path ""

      destroot.destdir prefix=${destroot}${prefix}
      platform darwin { global cgi_path httpd_conf_path httpd_doc_path
      set cgi_path "/Library/WebServer/CGI-Executables"
      set httpd_doc_path "/Library/WebServer/Documents"
      set httpd_conf_path "/private/etc/httpd"

      # apache darwinport interop
      if {[ file exists ${prefix}/sbin/httpd]} {
      set cgi_path "${prefix}/www/cgi-bin"
      set httpd_doc_path "${prefix}/www/htdocs"
      set httpd_conf_path "${prefix}/etc/apache"
      }
      configure.args --with-cgi-bin-dir=${destroot}${cgi_path} }

      platform darwin 8 powerpc {
      configure.compiler gcc-3.3
      }

      platform freebsd { global cgi_path httpd_conf_path httpd_doc_path
      set cgi_path "/usr/local/www/cgi-bin"
      set httpd_doc_path "/usr/local/www/data"
      set httpd_conf_path "/usr/local/etc/apache"

      # apache darwinport interop
      if {[ file exists ${prefix}/sbin/httpd]} {
      set cgi_path "${prefix}/www/cgi-bin"
      set httpd_doc_path "${prefix}/www/htdocs"
      set httpd_conf_path "${prefix}/etc/apache"
      }
      configure.args --with-cgi-bin-dir=${destroot}${cgi_path} }

      post-destroot { # Empty directory hack
      file mkdir ${destroot}${db_path}
      system "touch ${destroot}${db_path}/.turd"

      # Install documentation
      file mkdir ${destroot}${doc_path}
      system "cd ${worksrcpath}/htdoc && tar -cf - *.html *.gif *.css | tar -xf - -C ${destroot}${doc_path}"
      system "chown -R `id -u`:`id -g` ${destroot}${doc_path}"

      # Create symbolic link in web server doc root
      file mkdir ${destroot}${httpd_doc_path}
      system "cd ${destroot}${httpd_doc_path} && ln -s ${share_path}/search.html"

      # Fix paths in rundig script
      reinplace "s|${destroot}${prefix}|${prefix}|g" "${destroot}${prefix}/bin/rundig"

      # Fix paths in htdig config file
      reinplace "s|${destroot}${prefix}|${prefix}|g" "${destroot}${conf_path}/${name}.conf"

      # Make copy of htdig config file
      system "install -m 644 ${destroot}${conf_path}/${name}.conf ${destroot}${share_path}/${name}.conf.default"

      # Install default htdig apache config file
      file mkdir ${destroot}${httpd_conf_path}
      system "install -m 644 ${portpath}/${filesdir}/httpd.conf ${destroot}${httpd_conf_path}/httpd_${name}.conf"
      reinplace "s|DP_PREFIX|${prefix}|g" "${destroot}${httpd_conf_path}/httpd_${name}.conf"
      reinplace "s|NAME|${name}|g" "${destroot}${httpd_conf_path}/httpd_${name}.conf"
      reinplace "s|VERSION|${version}|g" "${destroot}${httpd_conf_path}/httpd_${name}.conf"

      # Install contributed scripts
      file mkdir ${destroot}${share_path}/contrib
      system "cd ${worksrcpath}/contrib && tar -cf - * | tar -xf - -C ${destroot}${share_path}/contrib"
      system "chown -R `id -u`:`id -g` ${destroot}${share_path}/contrib"
      }


    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/htdig
      % sudo port install htdig
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching htdig
      ---> Verifying checksum for htdig
      ---> Extracting htdig
      ---> Configuring htdig
      ---> Building htdig with target all
      ---> Staging htdig into destroot
      ---> Installing htdig
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using htdig with these commands:
      %  man htdig
      % apropos htdig
      % which htdig
      % locate htdig

     Where to find more information:

    Darwin Ports



    image test