<commit_before>class Gpsbabel < Formula
  desc "Converts/uploads GPS waypoints, tracks, and routes"
  homepage "https://www.gpsbabel.org/"
  url "https://github.com/gpsbabel/gpsbabel/archive/gpsbabel_1_7_0.tar.gz"
  sha256 "30b186631fb43db576b8177385ed5c31a5a15c02a6bc07bae1e0d7af9058a797"
  license "GPL-2.0"
  revision 1

  livecheck do
    url :stable
    regex(/^gpsbabel[._-]v?(\d+(?:[._]\d+)+)$/i)
  end

  bottle do
    sha256 big_sur:  "6d5c179704f46781438a06f02a6e83c0d9e5bfa3af0f15b738af0029a4cc56af"
    sha256 catalina: "c71c3f2662684e9c03cac17d2f211b58ee07b3dc64ce74121922cca41d6b303c"
    sha256 mojave:   "0a8e9cb2650be7396304d7486975e4ef82dce6e1890f8f54cbbaa0e05ab99991"
  end

  depends_on "pkg-config" => :build
  depends_on "libusb"
  depends_on "qt@5"
  depends_on "shapelib"

  uses_from_macos "zlib"

  # upstream https://github.com/gpsbabel/gpsbabel/pull/611 added support for configuration of third party libraries.
  patch do<commit_msg>gpsbabel: fix build on Linux (#84538)<commit_after>class Gpsbabel < Formula
  desc "Converts/uploads GPS waypoints, tracks, and routes"
  homepage "https://www.gpsbabel.org/"
  url "https://github.com/gpsbabel/gpsbabel/archive/gpsbabel_1_7_0.tar.gz"
  sha256 "30b186631fb43db576b8177385ed5c31a5a15c02a6bc07bae1e0d7af9058a797"
  license "GPL-2.0-or-later"
  revision 1

  livecheck do
    url :stable
    regex(/^gpsbabel[._-]v?(\d+(?:[._]\d+)+)$/i)
  end

  bottle do
    sha256 big_sur:  "6d5c179704f46781438a06f02a6e83c0d9e5bfa3af0f15b738af0029a4cc56af"
    sha256 catalina: "c71c3f2662684e9c03cac17d2f211b58ee07b3dc64ce74121922cca41d6b303c"
    sha256 mojave:   "0a8e9cb2650be7396304d7486975e4ef82dce6e1890f8f54cbbaa0e05ab99991"
  end

  depends_on "pkg-config" => :build
  depends_on "libusb"
  depends_on "qt@5"
  depends_on "shapelib"

  uses_from_macos "zlib"

  on_linux do
    depends_on "gcc"
  end

  fails_with gcc: "5"

  # upstream https://github.com/gpsbabel/gpsbabel/pull/611 added support for configuration of third party libraries.
  patch do
{'fraction_non_alphanumeric': 0.09940652818991098, 'fraction_numerical': 0.18397626112759644, 'mean_word_length': 4.880813953488372, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 6, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '874313', 'n_tokens_mistral': 1105, 'n_tokens_neox': 914, 'n_words': 134}