<commit_before>require 'formula'

class Abyss < Formula
  homepage 'http://www.bcgsc.ca/platform/bioinfo/software/abyss'
  #doi '10.1101/gr.089532.108'
  #tag "bioinformatics"
  url 'https://github.com/bcgsc/abyss/releases/download/1.5.2/abyss-1.5.2.tar.gz'
  sha1 'f28189338efdee0167cf73f92b43181caccd2b1d'

  head do
    url 'https://github.com/bcgsc/abyss.git'

    depends_on :autoconf => :build
    depends_on :automake => :build
    depends_on 'multimarkdown' => :build
  end

  resource "gtest" do
    #homepage "https://code.google.com/p/googletest/"
    url "https://googletest.googlecode.com/files/gtest-1.7.0.zip"
    sha1 "f85f6d2481e2c6c4a18539e391aa4ea8ab0394af"
  end

  option "without-check", "Skip build-time tests (not recommended)"

  MAXK = [32, 64, 96, 128, 256, 512]
  MAXK.each do |k|
    option "enable-maxk=#{k}", "set the maximum k-mer length to #{k}"
  end

  # Only header files are used from these packages, so :build is appropriate
  depends_on 'boost' => :build
  depends_on 'google-sparsehash' => :build
  depends_on :mpi => [:cc, :recommended]

  # strip breaks the ability to read compressed files.
  skip_clean 'bin'

  def install
    resource("gtest").stage do
      system "./configure"
      system "make"
      (buildpath/"gtest").install "include", "lib"
    end if build.with? "check"<commit_msg>abyss 1.5.2: Fix gtest<commit_after>require 'formula'

class Abyss < Formula
  homepage 'http://www.bcgsc.ca/platform/bioinfo/software/abyss'
  #doi '10.1101/gr.089532.108'
  #tag "bioinformatics"
  url 'https://github.com/bcgsc/abyss/releases/download/1.5.2/abyss-1.5.2.tar.gz'
  sha1 'f28189338efdee0167cf73f92b43181caccd2b1d'

  head do
    url 'https://github.com/bcgsc/abyss.git'

    depends_on :autoconf => :build
    depends_on :automake => :build
    depends_on 'multimarkdown' => :build
  end

  resource "gtest" do
    #homepage "https://code.google.com/p/googletest/"
    url "https://googletest.googlecode.com/files/gtest-1.7.0.zip"
    sha1 "f85f6d2481e2c6c4a18539e391aa4ea8ab0394af"
  end

  option "without-check", "Skip build-time tests (not recommended)"

  MAXK = [32, 64, 96, 128, 256, 512]
  MAXK.each do |k|
    option "enable-maxk=#{k}", "set the maximum k-mer length to #{k}"
  end

  # Only header files are used from these packages, so :build is appropriate
  depends_on 'boost' => :build
  depends_on 'google-sparsehash' => :build
  depends_on :mpi => [:cc, :recommended]

  # strip breaks the ability to read compressed files.
  skip_clean 'bin'

  def install
    resource("gtest").stage do
      system "make", "-C", "make"
      (buildpath/"gtest").install "include"
      (buildpath/"gtest/lib").install "make/gtest_main.a" => "libgtest_main.a"
    end if build.with? "check"
{'fraction_non_alphanumeric': 0.14093226511289147, 'fraction_numerical': 0.06518572469045884, 'mean_word_length': 3.578333333333333, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 16, 'https://': 8, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '6353796', 'n_tokens_mistral': 1165, 'n_tokens_neox': 1041, 'n_words': 230}