void-packages/srcpkgs/ucpp/template

27 lines
746 B
Bash

# Template file for 'ucpp'
pkgname=ucpp
version=1.3.2
revision=2
build_style=gnu-makefile
short_desc="Embeddable, quick and light C99 compliant C preprocessor"
maintainer="Orphaned <orphan@voidlinux.org>"
license="BSD-3-Clause"
homepage="https://code.google.com/archive/p/ucpp/"
distfiles="https://storage.googleapis.com/google-code-archive-downloads/v2/code.google.com/ucpp/ucpp-${version}.tar.bz2"
checksum=ab7ecc5ba2c2617fa14cd0a939c1e87ed789c59767fb39fc9b7d0ebf63a81635
nopie=yes
pre_build() {
vsed -i Makefile \
-e "s;^CC = .*;CC = ${CC};" \
-e "s;^FLAGS = .*;FLAGS = ${CFLAGS};" \
-e "s;^#LDFLAGS = -pg;LDFLAGS = ${LDFLAGS};"
}
do_install() {
vbin ucpp
vman ucpp.1
head -n 27 Makefile | tail -n 25 > LICENSE
vlicense LICENSE
}