opendetex: unbundle detex from texlive_core

This commit is contained in:
Joachim Mairböck
2024-08-20 15:14:15 +02:00
parent afc70bbc04
commit 188026f6c8
4 changed files with 119 additions and 2 deletions

View File

@@ -96,7 +96,6 @@ PROVIDES="
cmd:cweave
cmd:de_macro
cmd:depythontex
cmd:detex
cmd:devnag
cmd:diadia
cmd:digestif
@@ -573,7 +572,6 @@ defineDebugInfoPackage texlive_core$secondaryArchSuffix \
$prefix/bin/ctwill-refsort \
$prefix/bin/ctwill-twinx \
$prefix/bin/cweave \
$prefix/bin/detex \
$prefix/bin/devnag \
$prefix/bin/disdvi \
$prefix/bin/dt2dv \
@@ -868,6 +866,7 @@ BUILD()
--without-x \
--disable-chktex \
--disable-cjkutils \
--disable-detex \
--disable-t1utils \
--build=$HOST --host=$HOST

View File

@@ -0,0 +1,15 @@
University of Illinois/NCSA Open Source License
Copyright (c) <Year> <Owner Organization Name>. All rights reserved.
Developed by: <Name of Development Group> <Name of Institution> <URL for Development Group/Institution>
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal with the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
* Redistributions of source code must retain the above copyright notice, this list of conditions and the following disclaimers.
* Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the following disclaimers in the documentation and/or other materials provided with the distribution.
* Neither the names of <Name of Development Group, Name of Institution>, nor the names of its contributors may be used to endorse or promote products derived from this Software without specific prior written permission.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE CONTRIBUTORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS WITH THE SOFTWARE.

View File

@@ -0,0 +1,54 @@
SUMMARY="Tool for extracting plain text from TeX and LaTeX sources"
DESCRIPTION="OpenDetex is a program to remove TeX constructs from a text file. It recognizes the \
\\input command.
This program assumes it is dealing with LaTeX input if it sees the string \"\\begin{document}\" \
in the text. It recognizes the \\include and \\includeonly commands."
HOMEPAGE="https://github.com/pkubowicz/opendetex"
COPYRIGHT="1986-2007 Purdue University"
LICENSE="NCSA"
REVISION="1"
SOURCE_URI="https://github.com/pkubowicz/opendetex/releases/download/v$portVersion/opendetex-$portVersion.tar.bz2"
CHECKSUM_SHA256="f5771afc607134f65d502d733552cbc79ef06eee44601ae8077b79d852daa05f"
SOURCE_DIR=""
PATCHES="opendetex-$portVersion.patchset"
ARCHITECTURES="all"
PROVIDES="
opendetex = $portVersion
cmd:detex = $portVersion
"
REQUIRES="
haiku
"
BUILD_REQUIRES="
haiku_devel
devel:libfl
"
BUILD_PREREQUIRES="
cmd:gcc
cmd:make
"
defineDebugInfoPackage opendetex \
$binDir/detex
BUILD()
{
make $jobArgs
}
INSTALL()
{
mkdir -p $binDir $manDir/man1
make install PREFIX=$prefix MANDIR=$manDir
}
TEST()
{
# Tests aren't included in the release tarball
#make test
true
}

View File

@@ -0,0 +1,49 @@
From 5e4fb1832b5abc15db55e8e814646116dd189c89 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Joachim=20Mairb=C3=B6ck?= <j.mairboeck@gmail.com>
Date: Tue, 20 Aug 2024 15:04:53 +0200
Subject: Makefile: make install paths configurable
diff --git a/Makefile b/Makefile
index 13443a0..d9b07a7 100644
--- a/Makefile
+++ b/Makefile
@@ -42,7 +42,9 @@ UNAME_S := $(shell uname -s)
# Installation directory
#
-DESTDIR = /usr/local/bin
+PREFIX = /usr/local
+BINDIR = ${PREFIX}/bin
+MANDIR = ${PREFIX}/share/man
# Specify you favorite compiler
#
@@ -125,16 +127,16 @@ man-page:
# If you want detex available as delatex, uncomment the last two lines of
# this target
install: all
- rm -f ${DESTDIR}/detex
- install -c -m 775 -g staff -s detex ${DESTDIR}
- install detex.1 /usr/local/share/man/man1
-# rm -f ${DESTDIR}/delatex
-# ln ${DESTDIR}/detex ${DESTDIR}/delatex
+ rm -f ${BINDIR}/detex
+ install -c -m 755 -s detex ${BINDIR}
+ install detex.1 ${MANDIR}/man1
+# rm -f ${BINDIR}/delatex
+# ln -s detex ${BINDIR}/delatex
uninstall:
- rm -f ${DESTDIR}/detex
- rm -f ${DESTDIR}/delatex
- rm -f /usr/local/share/man/man1/detex.*
+ rm -f ${BINDIR}/detex
+ rm -f ${BINDIR}/delatex
+ rm -f ${MANDIR}/man1/detex.*
clean:
-rm -f a.out core *.s *.o ERRS errs .,* .emacs_[0-9]*
--
2.45.2