<commit_before>class Gle < Formula
  homepage "http://glx.sourceforge.net/"
  url "https://downloads.sourceforge.net/glx/gle-graphics-4.2.4cf-src.tar.gz"
  version "4.2.4c"
  sha256 "21715f2943ca528ec94a8e129175693afc3b59bb03f92540a2150ffe72ab47ef"

  depends_on "pkg-config" => :build
  depends_on :x11
  depends_on "jpeg" => :optional
  depends_on "libtiff" => :optional
  depends_on "cairo"

  # fix namespace issues causing compilation errors
  # https://trac.macports.org/ticket/41760
  patch :p0 do
    url "https://trac.macports.org/raw-attachment/ticket/41760/patch-hash-map.diff"
    sha256 "59769465080c539573313411c301314b18aa407e61858ce3b42d9f3b0660b1e4"
  end

  def install
    system "./configure", "--prefix=#{prefix}",
                          "--with-arch=#{MacOS.preferred_arch}",
                          "--without-qt"

    inreplace "Makefile", "MKDIR_P", "mkdir -p"

    system "make"
    ENV.deparallelize
    system "make", "install"
  end
end
<commit_msg>gle: migrate patch to Homebrew/patches<commit_after>class Gle < Formula
  homepage "http://glx.sourceforge.net/"
  url "https://downloads.sourceforge.net/glx/gle-graphics-4.2.4cf-src.tar.gz"
  version "4.2.4c"
  sha256 "21715f2943ca528ec94a8e129175693afc3b59bb03f92540a2150ffe72ab47ef"

  depends_on "pkg-config" => :build
  depends_on :x11
  depends_on "jpeg" => :optional
  depends_on "libtiff" => :optional
  depends_on "cairo"

  # fix namespace issues causing compilation errors
  # https://trac.macports.org/ticket/41760
  patch :p0 do
    url "https://raw.githubusercontent.com/Homebrew/patches/985ba4f/gle/patch-hash-map.diff"
    sha256 "59769465080c539573313411c301314b18aa407e61858ce3b42d9f3b0660b1e4"
  end

  def install
    system "./configure", "--prefix=#{prefix}",
                          "--with-arch=#{MacOS.preferred_arch}",
                          "--without-qt"

    inreplace "Makefile", "MKDIR_P", "mkdir -p"

    system "make"
    ENV.deparallelize
    system "make", "install"
  end
end

{'fraction_non_alphanumeric': 0.128, 'fraction_numerical': 0.1165, 'mean_word_length': 3.2574468085106383, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 9, 'https://': 6, 'lorem ipsum': 0, 'www.': 0, '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': '3116967', 'n_tokens_mistral': 885, 'n_tokens_neox': 752, 'n_words': 122}