Files
chromebrew/packages/flex.rb
github-actions[bot] 626a53a7a7 Update buildsystems to use buildsystem name variables, and report contents of those variables/methods during use. (#11936)
* Update buildsystems, update jq, add jq to core for arm.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Only report build options if they exist.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Fix overeager sed replacement.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* workflow debugging

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add logging for build errors.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Revert to function in each package file.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Update jq since it needs gcc14 to build.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add built packages for linux/386 to buildsystems

* remove deprecated gfbgraph

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* fix git tag for gnome_maps

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Update llvm20 package file.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Update gnome_maps deps.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Abstract out buildsystems_methods reporting.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Keep LIBC_VERSION const from being empty.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Update crew_profile_base and libxml2

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* clarify

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* lint

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Update libarchive

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* update libavif

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* more updates

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add libxml2 build comment.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Add build comment to libarchive.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

* Don't warn for missing directory during package removal.

Signed-off-by: Satadru Pramanik <satadru@gmail.com>

---------

Signed-off-by: Satadru Pramanik <satadru@gmail.com>
Co-authored-by: Satadru Pramanik <satadru@gmail.com>
Co-authored-by: satmandu <satmandu@users.noreply.github.com>
2025-05-23 19:50:48 +00:00

38 lines
1.5 KiB
Ruby

require 'buildsystems/autotools'
class Flex < Autotools
description 'Flex (The Fast Lexical Analyzer) is a fast lexical analyser generator tool for generating programs that perform pattern-matching on text.'
homepage 'https://www.gnu.org/software/flex/'
version '2.6.4-2'
license 'BSD'
compatibility 'all'
source_url 'https://github.com/westes/flex/releases/download/v2.6.4/flex-2.6.4.tar.gz'
source_sha256 'e87aae032bf07c26f85ac0ed3250998c37621d95f8bd748b31f15b33c45ee995'
binary_compression 'tar.zst'
binary_sha256({
aarch64: '7968e998075c49c0b49d0db6d9d2fc49f1e1e35a283a1cd450db8b149191cfcc',
armv7l: '7968e998075c49c0b49d0db6d9d2fc49f1e1e35a283a1cd450db8b149191cfcc',
i686: '9fd42095b66754a94d1b09b242966275efcd41b39f75ca0ba504b75125a38bf9',
x86_64: 'c2dc3fd71ce8109b2bd2d8fa233e0082a772d50d0dcf5629cc105f2c5d8be8b6'
})
depends_on 'bison' => :build
depends_on 'glibc' # R
depends_on 'm4' => :build
autotools_configure_options '--with-pic --disable-static --enable-shared'
def self.patch
downloader 'https://gitlab.archlinux.org/archlinux/packaging/packages/flex/-/raw/main/flex-pie.patch?ref_type=heads&inline=false',
'20f3cce6b0ea6ab67a902a46b89c292b959994dedcbe6ee5d187f9bba1408b0e', 'flex-pie.patch'
system 'patch -p1 -i flex-pie.patch'
system 'autoreconf -fiv'
end
def self.install
system 'make', "DESTDIR=#{CREW_DEST_DIR}", 'install'
FileUtils.ln_s "#{CREW_PREFIX}/bin/flex", "#{CREW_DEST_PREFIX}/bin/lex"
end
end