mirror of
https://github.com/yann64/haikuports.git
synced 2026-03-19 01:46:00 +01:00
unifdef: add recipe
This commit is contained in:
30
dev-util/unifdef/patches/unifdef-2.12.patchset
Normal file
30
dev-util/unifdef/patches/unifdef-2.12.patchset
Normal file
@@ -0,0 +1,30 @@
|
||||
From 2a4cb3da67bd26284d32abeb7d699d70ce7646d5 Mon Sep 17 00:00:00 2001
|
||||
From: Gerasim Troeglazov <3dEyes@gmail.com>
|
||||
Date: Sun, 18 Dec 2022 00:03:45 +1000
|
||||
Subject: Fix build
|
||||
|
||||
|
||||
diff --git a/unifdef.h b/unifdef.h
|
||||
index 2cd706d..f61749c 100644
|
||||
--- a/unifdef.h
|
||||
+++ b/unifdef.h
|
||||
@@ -27,6 +27,7 @@
|
||||
|
||||
#include <ctype.h>
|
||||
#include <err.h>
|
||||
+#include <errno.h>
|
||||
#include <stdarg.h>
|
||||
#include <stdbool.h>
|
||||
#include <stdio.h>
|
||||
@@ -34,6 +35,8 @@
|
||||
#include <string.h>
|
||||
#include <unistd.h>
|
||||
|
||||
+#define _getprogname() "unifdef"
|
||||
+
|
||||
/* portability stubs */
|
||||
|
||||
#define fbinmode(fp) (fp)
|
||||
--
|
||||
2.37.3
|
||||
|
||||
45
dev-util/unifdef/unifdef-2.12.recipe
Normal file
45
dev-util/unifdef/unifdef-2.12.recipe
Normal file
@@ -0,0 +1,45 @@
|
||||
SUMMARY="Selectively remove C preprocessor conditionals"
|
||||
DESCRIPTION="The unifdef utility selectively processes conditional C \
|
||||
preprocessor #if and #ifdef directives. It removes from a file both \
|
||||
the directives and the additional text that they delimit, while \
|
||||
otherwise leaving the file alone."
|
||||
HOMEPAGE="https://dotat.at/prog/unifdef/"
|
||||
COPYRIGHT="Tony Finch"
|
||||
LICENSE="BSD (3-clause)"
|
||||
REVISION="1"
|
||||
SOURCE_URI="https://github.com/fanf2/unifdef/archive/refs/tags/unifdef-$portVersion.tar.gz"
|
||||
CHECKSUM_SHA256="030369db9ff917acfae7fa4e90bcc1dff8a8dc534d82d1c72c12ef698d2f20e4"
|
||||
SOURCE_DIR="unifdef-unifdef-$portVersion"
|
||||
PATCHES="unifdef-$portVersion.patchset"
|
||||
|
||||
ARCHITECTURES="all"
|
||||
|
||||
PROVIDES="
|
||||
unifdef = $portVersion
|
||||
cmd:unifdef
|
||||
"
|
||||
REQUIRES="
|
||||
haiku
|
||||
"
|
||||
|
||||
BUILD_REQUIRES="
|
||||
haiku_devel
|
||||
"
|
||||
BUILD_PREREQUIRES="
|
||||
cmd:gcc
|
||||
cmd:make
|
||||
"
|
||||
|
||||
BUILD()
|
||||
{
|
||||
chmod +x scripts/reversion.sh
|
||||
scripts/reversion.sh
|
||||
|
||||
gcc -o unifdef unifdef.c FreeBSD/err.c -I.
|
||||
}
|
||||
|
||||
INSTALL()
|
||||
{
|
||||
mkdir -p $binDir
|
||||
cp unifdef $binDir
|
||||
}
|
||||
Reference in New Issue
Block a user