Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 1 | SUMMARY = "Standard GNU compressor" |
| 2 | DESCRIPTION = "GNU Gzip is a popular data compression program originally written by Jean-loup Gailly for the GNU \ |
| 3 | project. Mark Adler wrote the decompression part" |
| 4 | HOMEPAGE = "http://www.gnu.org/software/gzip/" |
| 5 | SECTION = "console/utils" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 6 | |
| 7 | inherit autotools texinfo |
Patrick Williams | d8c66bc | 2016-06-20 12:57:21 -0500 | [diff] [blame] | 8 | export DEFS="NO_ASM" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 9 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 10 | EXTRA_OEMAKE:class-target = "GREP=${base_bindir}/grep" |
| 11 | EXTRA_OECONF:append:libc-musl = " gl_cv_func_fflush_stdin=yes " |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 12 | |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 13 | do_install:append () { |
Patrick Williams | f1e5d69 | 2016-03-30 15:21:19 -0500 | [diff] [blame] | 14 | if [ "${base_bindir}" != "${bindir}" ]; then |
| 15 | # Rename and move files into /bin (FHS), which is typical place for gzip |
| 16 | install -d ${D}${base_bindir} |
| 17 | mv ${D}${bindir}/gunzip ${D}${base_bindir}/gunzip |
| 18 | mv ${D}${bindir}/gzip ${D}${base_bindir}/gzip |
| 19 | mv ${D}${bindir}/zcat ${D}${base_bindir}/zcat |
| 20 | mv ${D}${bindir}/uncompress ${D}${base_bindir}/uncompress |
| 21 | fi |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 22 | } |
| 23 | |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 24 | inherit update-alternatives |
| 25 | |
| 26 | ALTERNATIVE_PRIORITY = "100" |
Patrick Williams | 213cb26 | 2021-08-07 19:21:33 -0500 | [diff] [blame] | 27 | ALTERNATIVE:${PN} = "gunzip gzip zcat" |
Patrick Williams | c124f4f | 2015-09-15 14:41:29 -0500 | [diff] [blame] | 28 | ALTERNATIVE_LINK_NAME[gunzip] = "${base_bindir}/gunzip" |
| 29 | ALTERNATIVE_LINK_NAME[gzip] = "${base_bindir}/gzip" |
| 30 | ALTERNATIVE_LINK_NAME[zcat] = "${base_bindir}/zcat" |
| 31 | |
| 32 | export CONFIG_SHELL="/bin/sh" |