Date: Sat, 18 Mar 2006 23:50:21 +0300 From: Boris Samorodov <bsam@ipt.ru> To: freebsd-emulation@freebsd.org Subject: [patch] for bsd.linux-rpm.mk (LINUX_DISTRIBUTION and more) Message-ID: <63077458@ho.ipt.ru>
next in thread | raw e-mail | index | archive | help
--=-=-=
Hello, List!
1. I propose to use LINUX_DISTRIBUTION and VERSION (LINUX_DIST and
LINUX_DIST_VER at the patch) at those ports which use USE_LINUX_RPM.
So far only "fedora" and "3" are defined (they are defaults).
The first option is intended to define to which distribution the port
belogs to but thereis no need to install the linux distribution
binaries. Current option USE_LINUX=foo implies installing linux
distribution foo.
2. Currently only files for linux_base ports are saved to directories
named after linux distribution names. There is no standard:
o the majority of the ports use DIS_SUBDIR= rpm -- no distribution
name, no version;
o x11/linux-XFree86-libs: DIST_SUBDIR= rpm/i386/suse -- no version;
o graphics/linux-png: DIST_SUBDIR= rpm/i386/fc3 -- combined
distribution and version.
I propose standard directory for fetching distfiles:
DIST_SUBDIR?= rpm/${LINUX_RPM_ARCH}/${LINUX_DIST}/${LINUX_DIST_VER}
The default directory may stay DIST_SUBDIR?= rpm.
WBR
--
Boris B. Samorodov, Research Engineer
InPharmTech Co, http://www.ipt.ru
Telephone & Internet Service Provider
--=-=-=
Content-Type: text/x-patch
Content-Disposition: attachment; filename=patch
Content-Description: patch for bsd.linux-rpm.mk
--- bsd.linux-rpm.mk.orig Thu Mar 16 22:13:54 2006
+++ bsd.linux-rpm.mk Sat Mar 18 22:31:36 2006
@@ -33,10 +34,30 @@
Linux_RPM_Post_Include= bsd.linux-rpm.mk
+# LINUX_DIST and LINUX_DIST_VER should be defined at the port's Makefile
+
+LINUX_DIST?= fedora
+LINUX_DIST_VER?= 3
+
+. if ${LINUX_DIST} == "fedora"
MASTER_SITES?= ${MASTER_SITE_FEDORA_LINUX}
-MASTER_SITE_SUBDIR?= 3/${LINUX_RPM_ARCH}/os/Fedora/RPMS/
+MASTER_SITE_SUBDIR?= ${LINUX_DIST_VER}/${LINUX_RPM_ARCH}/os/Fedora/RPMS \
+ updates/${LINUX_DIST_VER}/${LINUX_RPM_ARCH}
+MASTER_SITE_SRC_SUBDIR?= ${LINUX_DIST_VER}/SRPMS \
+ updates/${LINUX_DIST_VER}/SRPMS
+DIST_SUBDIR?= rpm/${LINUX_RPM_ARCH}/${LINUX_DIST}/${LINUX_DIST_VER}
+. endif
PKGNAMEPREFIX?= linux-
+# DISTFILES and SRC_DISTFILES assume that there is only one bindist
+# and one src file exists.
+# Please, define them at the port's Makefile in case
+# the assumption is not true.
+
+DISTFILES?= ${DISTNAME}${EXTRACT_SUFX}
+SRC_DISTFILES?= ${DISTNAME}${SRC_SUFX}
+DIST_SUBDIR?= rpm
+
EXTRACT_DEPENDS+= ${RPM2CPIO}:${PORTSDIR}/archivers/rpm
eXTRACT_CMD?= ${RPM2CPIO}
--=-=-=--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?63077458>
