summaryrefslogtreecommitdiffstats
path: root/multimedia
diff options
context:
space:
mode:
authorlioux <lioux@FreeBSD.org>2002-04-22 22:28:49 +0000
committerlioux <lioux@FreeBSD.org>2002-04-22 22:28:49 +0000
commita2e502468e05b495f606fd575be95d367a7ea408 (patch)
tree9756e76fab8972528be3e38717190615c77686b3 /multimedia
parent52345e4b33f2e3f2e6bac8904a17f442fbe0c776 (diff)
downloadFreeBSD-ports-a2e502468e05b495f606fd575be95d367a7ea408.zip
FreeBSD-ports-a2e502468e05b495f606fd575be95d367a7ea408.tar.gz
o After repo copy from divx4linux: this port will hold previous
DiVX version 4.0 - add NO_LATEST_LINK - install under divx4 prefixes Repo copy by: joe Approved by: kris (repo copy)
Diffstat (limited to 'multimedia')
-rw-r--r--multimedia/linux-divx4linux4/Makefile15
-rw-r--r--multimedia/linux-divx4linux4/pkg-comment2
-rw-r--r--multimedia/linux-divx4linux4/pkg-install78
-rw-r--r--multimedia/linux-divx4linux4/pkg-plist15
4 files changed, 97 insertions, 13 deletions
diff --git a/multimedia/linux-divx4linux4/Makefile b/multimedia/linux-divx4linux4/Makefile
index 0191ca1..a46272b 100644
--- a/multimedia/linux-divx4linux4/Makefile
+++ b/multimedia/linux-divx4linux4/Makefile
@@ -20,10 +20,13 @@ ONLY_FOR_ARCHS= i386
USE_LINUX_PREFIX= yes
WRKSRC= ${WRKDIR}/${DISTNAME:C/_.+$//}
NO_BUILD= yes
+NO_LATEST_LINK= yes
PLIST_SUB= PKGNAME="${PKGNAME}"
RELEASE_DATE= 20011010_4.02
+PKGDEINSTALL= ${PKGINSTALL}
+
post-patch:
.for ext in h linux txt
@${PERL} -pi -e "s/ //" ${WRKSRC}/*.${ext}
@@ -37,10 +40,14 @@ do-install:
.endfor
.endif
# Header file installation
- @${MKDIR} ${PREFIX}/usr/include/divx
- @${INSTALL_DATA} ${WRKSRC}/*.h ${PREFIX}/usr/include/divx
-# Library installation
- @${INSTALL_DATA} ${WRKSRC}/*.so ${PREFIX}/usr/lib
+ @${MKDIR} ${PREFIX}/usr/include/divx4
+ @${INSTALL_DATA} ${WRKSRC}/*.h ${PREFIX}/usr/include/divx4
+ @${MKDIR} ${PREFIX}/usr/lib/divx4
+ @${INSTALL_DATA} ${WRKSRC}/*.so ${PREFIX}/usr/lib/divx4
@${LINUXBASE}/sbin/ldconfig
+post-install:
+ @${SETENV} PKG_PREFIX=${PREFIX} ${SH} \
+ ${PKGINSTALL} ${PKGNAME} POST-INSTALL
+
.include <bsd.port.mk>
diff --git a/multimedia/linux-divx4linux4/pkg-comment b/multimedia/linux-divx4linux4/pkg-comment
index 3e39dea..7a83722 100644
--- a/multimedia/linux-divx4linux4/pkg-comment
+++ b/multimedia/linux-divx4linux4/pkg-comment
@@ -1 +1 @@
-Linux binary release of DivX (TM) Codec
+Linux binary release of DivX 4 (TM) Codec
diff --git a/multimedia/linux-divx4linux4/pkg-install b/multimedia/linux-divx4linux4/pkg-install
new file mode 100644
index 0000000..717da38
--- /dev/null
+++ b/multimedia/linux-divx4linux4/pkg-install
@@ -0,0 +1,78 @@
+#!/bin/sh
+# $FreeBSD$
+
+[ $# != 2 ] && exit 1
+PKGNAME=$1
+ACTION=$2
+
+LIB_DIR=/usr/lib/divx4
+ETC_DIR=${PKG_PREFIX}/etc
+
+ETC_FILE=ld.so.conf
+
+FMT=fmt
+GREP=grep
+LDCONFIG=/compat/linux/sbin/ldconfig
+PERL=perl
+
+case "$ACTION" in
+
+POST-INSTALL)
+ echo "$PKGNAME: ======> <======"
+
+ if [ -f ${ETC_DIR}/${ETC_FILE} ]
+ then
+IS_IT_THERE=`${GREP} -E -e "^${LIB_DIR}$" ${ETC_DIR}/${ETC_FILE}`
+
+ if [ -z "${IS_IT_THERE}" ]
+ then
+ echo "${LIB_DIR}" >> ${ETC_DIR}/${ETC_FILE}
+ fi
+
+ ${LDCONFIG}
+
+ else
+ echo "$PKGNAME: ERROR: There is NO ${ETC_DIR}/${ETC_FILE}" | ${FMT}
+ echo "$PKGNAME: ERROR: Check your system." | ${FMT}
+ fi
+
+ echo "$PKGNAME: ======> <======"
+ ;;
+
+DEINSTALL)
+ echo "$PKGNAME: ======> <======"
+
+ if [ -f ${ETC_DIR}/${ETC_FILE} ]
+ then
+IS_IT_THERE=`${GREP} -E -e "^${LIB_DIR}$" ${ETC_DIR}/${ETC_FILE}`
+
+ if [ -n "${IS_IT_THERE}" ]
+ then
+ ${PERL} -pi -e "s|^${LIB_DIR}\n$||" \
+ ${ETC_DIR}/${ETC_FILE}
+ else
+ echo "$PKGNAME: ERROR: Existing ${ETC_DIR}/${ETC_FILE} configuration file was modified by hand." | ${FMT}
+ echo "$PKGNAME: You probably edited it by hand. Therefore, I can't automatically modify it."
+ echo "$PKGNAME: There is no problem."
+ echo "$PKGNAME: Just make sure it does not contain a line with '${LIB_DIR}'"
+ fi
+
+ ${LDCONFIG}
+
+ else
+ echo "$PKGNAME: ERROR: There is NO ${ETC_DIR}/${ETC_FILE}" | ${FMT}
+ echo "$PKGNAME: ERROR: Check your system." | ${FMT}
+ fi
+
+ echo "$PKGNAME: ======> <======"
+ ;;
+
+PRE-INSTALL|POST-DEINSTALL)
+ ;;
+
+*)
+ exit 1
+ ;;
+esac
+
+exit
diff --git a/multimedia/linux-divx4linux4/pkg-plist b/multimedia/linux-divx4linux4/pkg-plist
index e0ce87d..695fccc 100644
--- a/multimedia/linux-divx4linux4/pkg-plist
+++ b/multimedia/linux-divx4linux4/pkg-plist
@@ -1,12 +1,11 @@
%%PORTDOCS%%usr/doc/%%PKGNAME%%/Codec Core Interface.txt
%%PORTDOCS%%usr/doc/%%PKGNAME%%/license.txt
%%PORTDOCS%%usr/doc/%%PKGNAME%%/RELNOTES.linux
-usr/include/divx/decore.h
-usr/include/divx/encore2.h
-usr/include/divx/mv_hint.h
-usr/lib/libdivxdecore.so
-usr/lib/libdivxencore.so
-@dirrm usr/include/divx
+usr/include/divx4/decore.h
+usr/include/divx4/encore2.h
+usr/include/divx4/mv_hint.h
+usr/lib/divx4/libdivxdecore.so
+usr/lib/divx4/libdivxencore.so
+@dirrm usr/lib/divx4
+@dirrm usr/include/divx4
%%PORTDOCS%%@dirrm usr/doc/%%PKGNAME%%
-@exec %D/sbin/ldconfig
-@unexec %D/sbin/ldconfig
OpenPOWER on IntegriCloud