summaryrefslogtreecommitdiff
path: root/emulators/suse100_base
diff options
context:
space:
mode:
authorjlam <jlam@pkgsrc.org>2007-07-29 05:18:36 +0000
committerjlam <jlam@pkgsrc.org>2007-07-29 05:18:36 +0000
commit33f30156fb37245b360bbc293320402ecf1aba41 (patch)
tree45cad36d8470a568b9136017b2dd79c9efcc65bc /emulators/suse100_base
parentffe106498e5f63e2e945d5b6b2ac8807a10ae78f (diff)
downloadpkgsrc-33f30156fb37245b360bbc293320402ecf1aba41.tar.gz
* Add new emulator framework in pkgsrc/mk/emulator that handles all
binary-only packages that require binary "emulation" on the native operating system. Please see pkgsrc/mk/emulator/README for more details. * Teach the plist framework to automatically use any existing PLIST.${EMUL_PLATFORM} as part of the default PLIST_SRC definition. * Convert all of the binary-only packages in pkgsrc to use the emulator framework. Most of them have been tested to install and deinstall correctly. This involves the following cleanup actions: * Remove use of custom PLIST code and use PLIST.${EMUL_PLATFORM} more consistently. * Simplify packages by using default INSTALL and DEINSTALL scripts instead of custom INSTALL/DEINSTALL code. * Remove "SUSE_COMPAT32" and "PKG_OPTIONS.suse" from pkgsrc. Packages only need to state exactly which emulations they support, and the framework handles any i386-on-x86_64 or sparc-on-sparc64 uses. * Remove "USE_NATIVE_LINUX" from pkgsrc. The framework will automatically detect when the package is installing on Linux. Specific changes to packages include: * Bump the PKGREVISIONs for all of the suse100* and suse91* packages due to changes in the +INSTALL/+DEINSTALL scripts used in all of the packages. * Remove pkgsrc/emulators/suse_linux, which is unused by any packages. * cad/lc -- remove custom code to create the distinfo file for all supported platforms; just use "emul-fetch" and "emul-distinfo" instead. * lang/Cg-compiler -- install the shared libraries under ${EMULDIR} instead of ${PREFIX}/lib so that compiled programs will find the shared libraries. * mail/thunderbird-bin-nightly -- update to latest binary distributions for supported platforms. * multimedia/ns-flash -- update Linux version to 9.0.48 as the older version is no longer available for interactive fetch. * security/uvscan -- set LD_LIBRARY_PATH explicitly so that it's not necessary to install library symlinks into ${EMULDIR}/usr/local/lib. * www/firefox-bin-flash -- update Linux version to 9.0.48 as the older version is no longer available for interactive fetch.
Diffstat (limited to 'emulators/suse100_base')
-rw-r--r--emulators/suse100_base/DEINSTALL27
-rw-r--r--emulators/suse100_base/DESCR9
-rw-r--r--emulators/suse100_base/INSTALL153
-rw-r--r--emulators/suse100_base/Makefile88
-rw-r--r--emulators/suse100_base/Makefile.i38614
-rw-r--r--emulators/suse100_base/Makefile.powerpc14
-rw-r--r--emulators/suse100_base/Makefile.x86_6416
-rw-r--r--emulators/suse100_base/PLIST18
-rw-r--r--emulators/suse100_base/files/SuSE-release4
-rw-r--r--emulators/suse100_base/files/linux-mkpwd.sh24
-rw-r--r--emulators/suse100_base/suse.i386.mk15
-rw-r--r--emulators/suse100_base/suse.powerpc.mk15
-rw-r--r--emulators/suse100_base/suse.x86_64.mk17
13 files changed, 272 insertions, 142 deletions
diff --git a/emulators/suse100_base/DEINSTALL b/emulators/suse100_base/DEINSTALL
new file mode 100644
index 00000000000..e37a030b640
--- /dev/null
+++ b/emulators/suse100_base/DEINSTALL
@@ -0,0 +1,27 @@
+# $NetBSD: DEINSTALL,v 1.1 2007/07/29 05:18:38 jlam Exp $
+
+EMULDIR="${PKG_PREFIX}/@EMULSUBDIR@"
+
+case "${STAGE}" in
+DEINSTALL)
+ # Run any actions that require root privileges.
+ ${TEST} ! -x ./+ROOT_ACTIONS ||
+ ./+ROOT_ACTIONS REMOVE ${PKG_METADATA_DIR} || exit 1
+
+ # Blow away the /proc directory
+ ${RM} -fr ${EMULDIR}/proc
+
+ # Remove a stray symlink that would normally be managed by
+ # ldconfig(8).
+ #
+ ${RM} -f ${EMULDIR}/usr/@LINUX_LIBSUBDIR@/libz.so.1
+
+ # Remove some files created by pkgsrc.
+ ${RM} -f ${EMULDIR}/etc/ld.so.cache
+ ${RM} -f ${EMULDIR}/etc/mtab
+ ${RM} -f ${EMULDIR}/etc/group
+ ${RM} -f ${EMULDIR}/etc/gshadow
+ ${RM} -f ${EMULDIR}/etc/passwd
+ ${RM} -f ${EMULDIR}/etc/shadow
+ ;;
+esac
diff --git a/emulators/suse100_base/DESCR b/emulators/suse100_base/DESCR
index 62e5a3f87e9..fa773614562 100644
--- a/emulators/suse100_base/DESCR
+++ b/emulators/suse100_base/DESCR
@@ -1,5 +1,6 @@
-Linux compatibility package based on the SuSE Linux distribution, take a
-look at "http://www.suse.com/" for more information about it.
+Linux compatibility package based on the SuSE Linux distribution.
+Please visit http://www.suse.com/ for more information about SuSE
+Linux.
-This package supports running ELF binaries linked with glibc2 which don't
-require X11 shared libraries.
+This package supports running ELF binaries linked with glibc2 that
+don't require X11 shared libraries.
diff --git a/emulators/suse100_base/INSTALL b/emulators/suse100_base/INSTALL
index ed22f89412e..51371f21458 100644
--- a/emulators/suse100_base/INSTALL
+++ b/emulators/suse100_base/INSTALL
@@ -1,30 +1,149 @@
-# $NetBSD: INSTALL,v 1.4 2007/04/19 15:30:20 xtraeme Exp $
+# $NetBSD: INSTALL,v 1.5 2007/07/29 05:18:39 jlam Exp $
-case "${STAGE}" in
-POST-INSTALL)
- emulsubdir="@OPSYS_EMULSUBDIR@"
+# Generate a +ROOT_ACTIONS script that runs certain actions that require
+# superuser privileges.
+#
+case "${STAGE},$1" in
+UNPACK,|UNPACK,+ROOT_ACTIONS)
+ ${CAT} > ./+ROOT_ACTIONS << 'EOF'
+#!@SH@
+#
+# +ROOT_ACTIONS - run actions requiring superuser privileges
+#
+# Usage: ./+ROOT_ACTIONS ADD|REMOVE [metadatadir]
+#
+# This script runs certain actions that require superuser privileges.
+# If such privileges are not available, then simply output a message
+# asking the user to run this script with the appropriate elevated
+# privileges.
+#
+
+CAT="@CAT@"
+CHMOD="@CHMOD@"
+CP="@CP@"
+ECHO="@ECHO@"
+ID="@ID@"
+LN="@LN@"
+MKDIR="@MKDIR@"
+PWD_CMD="@PWD_CMD@"
+RM="@RM@"
+SH="@SH@"
+TEST="@TEST@"
+
+SELF=$0
+ACTION=$1
+
+CURDIR=`${PWD_CMD}`
+PKG_METADATA_DIR="${2-${CURDIR}}"
+: ${PKGNAME=${PKG_METADATA_DIR##*/}}
+: ${PKG_PREFIX=@PREFIX@}
- emuldir="@OPSYS_EMULDIR@"
- pkgemuldir="${PKG_PREFIX}/emul/$emulsubdir"
+EMULDIR="${PKG_PREFIX}/@EMULSUBDIR@"
+OPSYS_EMULDIR="@OPSYS_EMULDIR@"
- emuldir_pwd=`cd $emuldir 2>/dev/null && ${PWD_CMD}`
- pkgemuldir_pwd=`cd $pkgemuldir 2>/dev/null && ${PWD_CMD}`
+ROOT_ACTIONS_COOKIE="${PKG_METADATA_DIR}/+ROOT_ACTIONS_done"
+EUID=`${ID} -u`
- if ${TEST} "$emuldir_pwd" != "$pkgemuldir_pwd"; then
- if ${TEST} -e $emuldir -o -L $emuldir; then
- ${CAT} << EOF
+exitcode=0
+case $ACTION,$EUID in
+ADD,0)
+ ${ECHO} "" > ${ROOT_ACTIONS_COOKIE}
+ ${CHMOD} g+w ${ROOT_ACTIONS_COOKIE}
+ # Create an appropriate Linux-like /dev directory.
+ ${ECHO} "${PKGNAME}: populating ${EMULDIR}/dev"
+ ${MKDIR} ${EMULDIR}/dev
+ ${TEST} ! -f /dev/MAKEDEV ||
+ ${CP} /dev/MAKEDEV ${EMULDIR}/dev
+ ${TEST} ! -f /dev/MAKEDEV.subr ||
+ ${CP} /dev/MAKEDEV.subr ${EMULDIR}/dev
+ ( cd ${EMULDIR}/dev &&
+ ${SH} ./MAKEDEV std audio &&
+ ${LN} -fs sound dsp )
+
+ # Create the appropriate symlink so that the kernel will
+ # find the installed files.
+ #
+ OPSYS_EMULDIR_PWD=`cd ${OPSYS_EMULDIR} 2>/dev/null && ${PWD_CMD}`
+ EMULDIR_PWD=`cd ${EMULDIR} 2>/dev/null && ${PWD_CMD}`
+
+ if ${TEST} "${OPSYS_EMULDIR_PWD}" != "${EMULDIR_PWD}"; then
+ if ${TEST} -e ${OPSYS_EMULDIR} -o -L ${OPSYS_EMULDIR}; then
+ ${CAT} << EOM
==============================================================================
-You must create a symbolic link for ${PKGNAME} to work properly:
+The following symbolic link must be created for ${PKGNAME}
+to work properly:
- $pkgemuldir -> $emuldir
+ ${EMULDIR} -> ${OPSYS_EMULDIR}
-It seems there is something else located at $emuldir.
==============================================================================
-EOF
+EOM
else
- ${MKDIR} -p `${DIRNAME} $emuldir` &&
- ${LN} -fs $pkgemuldir $emuldir
+ ${ECHO} "${PKGNAME}: creating symlink ${EMULDIR} -> ${OPSYS_EMULDIR}"
+ ( ${MKDIR} -p `${DIRNAME} ${OPSYS_EMULDIR}` &&
+ ${LN} -fs ${EMULDIR} ${OPSYS_EMULDIR} ) || ${TRUE}
fi
fi
;;
+
+REMOVE,0)
+ ${ECHO} "${PKGNAME}: removing ${EMULDIR}/dev"
+ ${RM} -fr ${EMULDIR}/dev
+ ${RM} -f ${ROOT_ACTIONS_COOKIE}
+ ;;
+
+ADD,*)
+ if ${TEST} ! -f ${ROOT_ACTIONS_COOKIE}; then
+ ${CAT} << EOM
+==============================================================================
+Please run the following command with superuser privileges to complete
+the installation of ${PKGNAME}:
+
+ cd ${PKG_METADATA_DIR} && ${SELF} ADD
+
+==============================================================================
+EOM
+ fi
+ ;;
+
+REMOVE,*)
+ if ${TEST} -f ${ROOT_ACTIONS_COOKIE}; then
+ ${CAT} << EOM
+==============================================================================
+Please run the following command with superuser privileges to begin the
+removal of ${PKGNAME}:
+
+ cd ${PKG_METADATA_DIR} && ${SELF} REMOVE
+
+Then, please run pkg_delete(1) again to complete the removal of this
+package.
+
+==============================================================================
+EOM
+ exitcode=1
+ fi
+ ;;
+esac
+exit $exitcode
+
+EOF
+ ${CHMOD} +x ./+ROOT_ACTIONS
+ ;;
+esac
+
+EMULDIR="${PKG_PREFIX}/@EMULSUBDIR@"
+OPSYS_EMULDIR="@OPSYS_EMULDIR@"
+
+case "${STAGE}" in
+POST-INSTALL)
+ # Create a /proc mount point.
+ ${MKDIR} -p ${EMULDIR}/proc
+
+ # Make /etc/mtab usable for Linux programs.
+ ${RM} -f ${EMULDIR}/etc/mtab
+ ${LN} -fs ${EMULDIR}/proc/mounts ${EMULDIR}/etc/mtab
+
+ # Run any actions that require root privileges.
+ ${TEST} ! -x ./+ROOT_ACTIONS ||
+ ./+ROOT_ACTIONS ADD ${PKG_METADATA_DIR}
+ ;;
esac
diff --git a/emulators/suse100_base/Makefile b/emulators/suse100_base/Makefile
index 2a6ee4703f2..aea3c7a1937 100644
--- a/emulators/suse100_base/Makefile
+++ b/emulators/suse100_base/Makefile
@@ -1,27 +1,18 @@
-# $NetBSD: Makefile,v 1.9 2007/04/19 15:30:20 xtraeme Exp $
+# $NetBSD: Makefile,v 1.10 2007/07/29 05:18:39 jlam Exp $
-DISTNAME= suse_base-${SUSE_VERSION}
-PKGREVISION= 3
-CATEGORIES= emulators
-MASTER_SITES= ${MASTER_SITE_SUSE100}
-DISTFILES= ${RPMFILES}
+DISTNAME= suse_base-${SUSE_VERSION}
+PKGREVISION= 4
+CATEGORIES= emulators
-MAINTAINER= tonio@NetBSD.org
-HOMEPAGE= http://www.suse.com/
-COMMENT= Linux compatibility package
+MAINTAINER= tonio@NetBSD.org
+COMMENT= Linux compatibility package
-CONFLICTS= linux_SuSE-5.3 linux_lib-2.4 linuxppc_lib-[0-9]*
+CONFLICTS= linux_SuSE-5.3 linux_lib-2.4 linuxppc_lib-[0-9]*
-# these files are handled by manually during de-/installation/pkg_add
-CHECK_FILES_SKIP+= ${PREFIX}/${EMULSUBDIR}/dev/.*
-CHECK_FILES_SKIP+= ${PREFIX}/${EMULSUBDIR}/etc/ld.so.cache
-
-EXTRACT_ONLY= # empty
-PLIST_SRC= ${WRKDIR}/PLIST_DYNAMIC
-PLIST_SUBST+= EMULSUBDIR=${EMULSUBDIR:Q} LINUX_LIB=${LINUX_LIB:Q} \
- SUSE_COMPAT32_SUFFIX=${SUSE_COMPAT32_SUFFIX:Q}
-
-.include "../../mk/bsd.prefs.mk"
+# These files are managed by the +INSTALL/+DEINSTALL scripts.
+CHECK_FILES_SKIP+= ${EMULDIR}/dev/.*
+CHECK_FILES_SKIP+= ${EMULDIR}/etc/ld.so.cache
+CHECK_FILES_SKIP+= ${EMULDIR}/usr/@LINUX_LIBSUBDIR@/libz.so.1
RPMIGNOREPATH= ./etc/bash.bashrc ./etc/bash_completion.d \
./etc/cron.daily ./etc/csh.cshrc ./etc/csh.login \
@@ -30,53 +21,36 @@ RPMIGNOREPATH= ./etc/bash.bashrc ./etc/bash_completion.d \
./etc/pam.d ./etc/profile ./etc/profile.dos \
./etc/rc.d.README ./etc/rpc ./etc/shells ./etc/ttytype
-LINUX_LDD= ${PREFIX}/${EMULSUBDIR}/usr/bin/ldd
-LINUX_LIB?= lib
+LINUX_LDD= ${EMULDIR}/usr/bin/ldd
+LINUX_LDCONFIG= ${EMULDIR}/usr/sbin/ldconfig
INSTALLATION_DIRS= sbin
+OWN_DIRS+= ${EMULSUBDIR}
+
+SUBST_CLASSES+= suse
+SUBST_STAGE.suse= do-build
+SUBST_FILES.suse= SuSE-release linux-mkpwd.sh
+SUBST_VARS.suse= EMULDIR SUSE_ARCH SUSE_VERSION
-SUSE_INCLUDE_MAKEFILE_ARCH= yes
+# Some platforms, e.g. FreeBSD, need to "brand" the ELF binaries to
+# the correct type.
+#
+BRANDELF_CMD= ${BRANDELF:D${BRANDELF} -t Linux ${LINUX_LDCONFIG}:U${TRUE}}
-do-build:
- @for FILE in ${FILESDIR}/SuSE-release ${FILESDIR}/*.sh; do \
- ${SED} -e 's#@@EMULDIR@@#${EMULDIR}#g' \
- -e 's#@@EMULSUBDIR@@#${EMULSUBDIR}#g' \
- -e 's#@@LINUX_LIB@@#${LINUX_LIB}#g' \
- -e 's#@@VERSION@@#${SUSE_VERSION}#g' \
- -e 's#@@ARCH@@#${SUSE_ARCH}#g' \
- $$FILE >${WRKDIR}/`basename $$FILE`; \
- done
+post-extract:
+ ${CP} ${FILESDIR}/SuSE-release ${WRKSRC}
+ ${CP} ${FILESDIR}/*.sh ${WRKSRC}
do-install:
- ${INSTALL_SCRIPT} ${FILESDIR}/linux-mkpwd.sh \
- ${PREFIX}/sbin/linux${SUSE_COMPAT32_SUFFIX}-mkpwd
- ${INSTALL_DATA_DIR} ${EMULDIR}/dev
- ${INSTALL_DATA} /dev/MAKEDEV ${EMULDIR}/dev
- if [ -f /dev/MAKEDEV.subr ]; then \
- ${INSTALL_DATA} /dev/MAKEDEV.subr ${EMULDIR}/dev; \
- fi
- cd ${EMULDIR}/dev && ${SH} ./MAKEDEV std audio
- cd ${EMULDIR}/dev && ${LN} -fs sound dsp
- @${CP} ${PKGDIR}/PLIST ${PLIST_SRC}
- ${RPM2PKG} ${RPM2PKGARGS}
- ${ECHO} "@dirrm ${EMULSUBDIR}" >>${PLIST_SRC}
- ${INSTALL_DATA} ${WRKDIR}/SuSE-release ${EMULDIR}/etc
- ${INSTALL_DATA_DIR} ${EMULDIR}/proc
- ${LN} -fs ${EMULDIR}/proc/mounts ${EMULDIR}/etc/mtab
-.if ${OPSYS} == "FreeBSD"
- ${BRANDELF} -t Linux ${EMULDIR}/sbin/ldconfig
-.endif
- ${EMULDIR}/sbin/ldconfig -r ${EMULDIR}
- ${ECHO} "@exec %D/${EMULSUBDIR}/sbin/ldconfig -r %D/${EMULSUBDIR}" \
- >>${PLIST_SRC}
- ${ECHO} "@unexec ${RMDIR} %D/${EMULSUBDIR}/etc 2>/dev/null || ${TRUE}" \
- >>${PLIST_SRC}
+ ${INSTALL_SCRIPT} ${WRKSRC}/linux-mkpwd.sh \
+ ${PREFIX}/sbin/${LINUX_BASE}-mkpwd
+ ${INSTALL_DATA} ${WRKSRC}/SuSE-release ${EMULDIR}/etc
+ ${BRANDELF_CMD}
${SED} -e 's:#! :#! ${EMULDIR}:' \
-e 's:^RTLD=:RTLD=/${EMULSUBDIR}:' \
- < ${LINUX_LDD} > ${LINUX_LDD}.new
+ ${LINUX_LDD} > ${LINUX_LDD}.new
${MV} ${LINUX_LDD}.new ${LINUX_LDD}
${CHMOD} +x ${LINUX_LDD}
- @${SETENV} PKG_PREFIX="${PREFIX}" ${SH} ${INSTALL_FILE} - POST-INSTALL
.include "../../emulators/suse100_linux/Makefile.common"
.include "../../mk/bsd.pkg.mk"
diff --git a/emulators/suse100_base/Makefile.i386 b/emulators/suse100_base/Makefile.i386
deleted file mode 100644
index d5ab050b105..00000000000
--- a/emulators/suse100_base/Makefile.i386
+++ /dev/null
@@ -1,14 +0,0 @@
-# $NetBSD: Makefile.i386,v 1.2 2006/06/06 14:53:06 salo Exp $
-
-RPMFILES= aaa_base-10.0-28.${SUSE_ARCH}.rpm \
- bash-3.0-17.${SUSE_ARCH}.rpm \
- coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm \
- glibc-2.3.5-40.${SUSE_ARCH}.rpm \
- libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- libacl-2.2.31-3.${SUSE_ARCH}.rpm \
- libattr-2.4.24-2.${SUSE_ARCH}.rpm \
- libselinux-1.23.11-3.${SUSE_ARCH}.rpm \
- libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- ncurses-5.4-71.${SUSE_ARCH}.rpm \
- readline-5.0-9.${SUSE_ARCH}.rpm \
- zlib-1.2.3-3.${SUSE_ARCH}.rpm
diff --git a/emulators/suse100_base/Makefile.powerpc b/emulators/suse100_base/Makefile.powerpc
deleted file mode 100644
index 2d3601c5ae6..00000000000
--- a/emulators/suse100_base/Makefile.powerpc
+++ /dev/null
@@ -1,14 +0,0 @@
-# $NetBSD: Makefile.powerpc,v 1.2 2006/06/06 14:53:06 salo Exp $
-
-RPMFILES= aaa_base-10.0-28.${SUSE_ARCH}.rpm \
- bash-3.0-17.${SUSE_ARCH}.rpm \
- coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm \
- glibc-2.3.5-40.${SUSE_ARCH}.rpm \
- libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- libacl-2.2.31-3.${SUSE_ARCH}.rpm \
- libattr-2.4.24-2.${SUSE_ARCH}.rpm \
- libselinux-1.23.11-3.${SUSE_ARCH}.rpm \
- libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- ncurses-5.4-71.${SUSE_ARCH}.rpm \
- readline-5.0-9.${SUSE_ARCH}.rpm \
- zlib-1.2.3-3.${SUSE_ARCH}.rpm
diff --git a/emulators/suse100_base/Makefile.x86_64 b/emulators/suse100_base/Makefile.x86_64
deleted file mode 100644
index fd5652311d5..00000000000
--- a/emulators/suse100_base/Makefile.x86_64
+++ /dev/null
@@ -1,16 +0,0 @@
-# $NetBSD: Makefile.x86_64,v 1.2 2006/06/06 14:53:06 salo Exp $
-
-RPMFILES= aaa_base-10.0-28.${SUSE_ARCH}.rpm \
- bash-3.0-17.${SUSE_ARCH}.rpm \
- coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm \
- glibc-2.3.5-40.${SUSE_ARCH}.rpm \
- libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- libacl-2.2.31-3.${SUSE_ARCH}.rpm \
- libattr-2.4.24-2.${SUSE_ARCH}.rpm \
- libselinux-1.23.11-3.${SUSE_ARCH}.rpm \
- libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm \
- ncurses-5.4-71.${SUSE_ARCH}.rpm \
- readline-5.0-9.${SUSE_ARCH}.rpm \
- zlib-1.2.3-3.${SUSE_ARCH}.rpm
-
-LINUX_LIB= lib64
diff --git a/emulators/suse100_base/PLIST b/emulators/suse100_base/PLIST
index 7f94deb4cf5..d45388bb83f 100644
--- a/emulators/suse100_base/PLIST
+++ b/emulators/suse100_base/PLIST
@@ -1,15 +1,3 @@
-@comment $NetBSD: PLIST,v 1.2 2007/04/19 15:30:20 xtraeme Exp $
-sbin/linux${SUSE_COMPAT32_SUFFIX}-mkpwd
-@unexec ${RM} -f %D/${EMULSUBDIR}/etc/ld.so.cache
-${EMULSUBDIR}/etc/SuSE-release
-${EMULSUBDIR}/etc/mtab
-${EMULSUBDIR}/usr/${LINUX_LIB}/libz.so.1
-@exec ${MKDIR} %D/${EMULSUBDIR}/proc
-@dirrm ${EMULSUBDIR}/proc
-@unexec cd %D/${EMULSUBDIR}/etc && ${RM} -f group gshadow passwd shadow
-@exec ${MKDIR} %D/${EMULSUBDIR}/dev
-@exec cp -p /dev/MAKEDEV %D/${EMULSUBDIR}/dev
-@exec cd %D/${EMULSUBDIR}/dev && sh ./MAKEDEV std audio
-@exec cd %D/${EMULSUBDIR}/dev && ln -s sound dsp
-@unexec ${RM} -f %D/${EMULSUBDIR}/dev/*
-@dirrm ${EMULSUBDIR}/dev
+@comment $NetBSD: PLIST,v 1.3 2007/07/29 05:18:40 jlam Exp $
+sbin/${LINUX_BASE}-mkpwd
+${EMULSUBDIRSLASH}etc/SuSE-release
diff --git a/emulators/suse100_base/files/SuSE-release b/emulators/suse100_base/files/SuSE-release
index 247032986b2..728e5a77870 100644
--- a/emulators/suse100_base/files/SuSE-release
+++ b/emulators/suse100_base/files/SuSE-release
@@ -1,2 +1,2 @@
-SuSE Linux @@VERSION@@ (@@ARCH@@)
-VERSION = @@VERSION@@
+SuSE Linux @SUSE_VERSION@ (@SUSE_ARCH@)
+VERSION = @SUSE_VERSION@
diff --git a/emulators/suse100_base/files/linux-mkpwd.sh b/emulators/suse100_base/files/linux-mkpwd.sh
index d751a771b8d..24409a0fc7c 100644
--- a/emulators/suse100_base/files/linux-mkpwd.sh
+++ b/emulators/suse100_base/files/linux-mkpwd.sh
@@ -1,13 +1,31 @@
#!/bin/sh
#
-# $NetBSD: linux-mkpwd.sh,v 1.1.1.1 2006/03/09 20:34:10 tonio Exp $
+# $NetBSD: linux-mkpwd.sh,v 1.2 2007/07/29 05:18:40 jlam Exp $
+#
+
+######################################################################
+#
+# NAME
+# @LINUX_BASE@-mkpwd -- create passwd/group files for COMPAT_LINUX
+#
+# SYNOPSYS
+# @LINUX_BASE@-mkpwd
+#
+# DESCRIPTION
+# @LINUX_BASE@-mkpwd creates passwd and group files and databases
+# for a COMPAT_LINUX installation based on the files found in
+# /etc, e.g. /etc/passwd, /etc/master.passwd, /etc/group, etc.
+#
+######################################################################
SRCDIR=/etc
-DESTDIR=@@EMULDIR@@/etc
+DESTDIR=@EMULDIR@/etc
+
+[ -d $DESTDIR ] || exit 1
umask 22
cd $DESTDIR
-cp $SRCDIR/passwd .
+cp -f $SRCDIR/passwd .
sed s/^wheel:/root:/ <$SRCDIR/group >group
umask 77
diff --git a/emulators/suse100_base/suse.i386.mk b/emulators/suse100_base/suse.i386.mk
new file mode 100644
index 00000000000..e666685287c
--- /dev/null
+++ b/emulators/suse100_base/suse.i386.mk
@@ -0,0 +1,15 @@
+# $NetBSD: suse.i386.mk,v 1.1 2007/07/29 05:18:40 jlam Exp $
+
+# SuSE i386 RPMs
+DISTFILES+= aaa_base-10.0-28.${SUSE_ARCH}.rpm
+DISTFILES+= bash-3.0-17.${SUSE_ARCH}.rpm
+DISTFILES+= coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm
+DISTFILES+= glibc-2.3.5-40.${SUSE_ARCH}.rpm
+DISTFILES+= libacl-2.2.31-3.${SUSE_ARCH}.rpm
+DISTFILES+= libattr-2.4.24-2.${SUSE_ARCH}.rpm
+DISTFILES+= libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= libselinux-1.23.11-3.${SUSE_ARCH}.rpm
+DISTFILES+= libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= ncurses-5.4-71.${SUSE_ARCH}.rpm
+DISTFILES+= readline-5.0-9.${SUSE_ARCH}.rpm
+DISTFILES+= zlib-1.2.3-3.${SUSE_ARCH}.rpm
diff --git a/emulators/suse100_base/suse.powerpc.mk b/emulators/suse100_base/suse.powerpc.mk
new file mode 100644
index 00000000000..01000e50ded
--- /dev/null
+++ b/emulators/suse100_base/suse.powerpc.mk
@@ -0,0 +1,15 @@
+# $NetBSD: suse.powerpc.mk,v 1.1 2007/07/29 05:18:40 jlam Exp $
+
+# SuSE PowerPC RPMs
+DISTFILES+= aaa_base-10.0-28.${SUSE_ARCH}.rpm
+DISTFILES+= bash-3.0-17.${SUSE_ARCH}.rpm
+DISTFILES+= coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm
+DISTFILES+= glibc-2.3.5-40.${SUSE_ARCH}.rpm
+DISTFILES+= libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= libacl-2.2.31-3.${SUSE_ARCH}.rpm
+DISTFILES+= libattr-2.4.24-2.${SUSE_ARCH}.rpm
+DISTFILES+= libselinux-1.23.11-3.${SUSE_ARCH}.rpm
+DISTFILES+= libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= ncurses-5.4-71.${SUSE_ARCH}.rpm
+DISTFILES+= readline-5.0-9.${SUSE_ARCH}.rpm
+DISTFILES+= zlib-1.2.3-3.${SUSE_ARCH}.rpm
diff --git a/emulators/suse100_base/suse.x86_64.mk b/emulators/suse100_base/suse.x86_64.mk
new file mode 100644
index 00000000000..b604c3c18ba
--- /dev/null
+++ b/emulators/suse100_base/suse.x86_64.mk
@@ -0,0 +1,17 @@
+# $NetBSD: suse.x86_64.mk,v 1.1 2007/07/29 05:18:40 jlam Exp $
+
+# SuSE x86_64 RPMs
+DISTFILES+= aaa_base-10.0-28.${SUSE_ARCH}.rpm
+DISTFILES+= bash-3.0-17.${SUSE_ARCH}.rpm
+DISTFILES+= coreutils-5.3.0-20.2.${SUSE_ARCH}.rpm
+DISTFILES+= glibc-2.3.5-40.${SUSE_ARCH}.rpm
+DISTFILES+= libgcc-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= libacl-2.2.31-3.${SUSE_ARCH}.rpm
+DISTFILES+= libattr-2.4.24-2.${SUSE_ARCH}.rpm
+DISTFILES+= libselinux-1.23.11-3.${SUSE_ARCH}.rpm
+DISTFILES+= libstdc++-4.0.2_20050901-3.${SUSE_ARCH}.rpm
+DISTFILES+= ncurses-5.4-71.${SUSE_ARCH}.rpm
+DISTFILES+= readline-5.0-9.${SUSE_ARCH}.rpm
+DISTFILES+= zlib-1.2.3-3.${SUSE_ARCH}.rpm
+
+LINUX_LIBSUBDIR= lib64