diff options
| -rw-r--r-- | remote/modules/kdm/data/etc/tmpfiles.d/kdm.conf | 2 | ||||
| -rw-r--r-- | remote/modules/kdm/kdm.build | 1 | ||||
| -rw-r--r-- | remote/modules/pam/data/etc/tmpfiles.d/pipefs.conf | 2 | ||||
| -rw-r--r-- | remote/modules/pam/pam.build | 15 | ||||
| -rw-r--r-- | remote/modules/plymouth/data/etc/tmpfiles.d/plymouth.conf | 2 | ||||
| -rw-r--r-- | remote/modules/plymouth/plymouth.conf | 3 | ||||
| -rw-r--r-- | remote/modules/sshd/data/etc/tmpfiles.d/sshd.conf | 2 | ||||
| -rw-r--r-- | remote/rootfs/rootfs-stage32/rootfs-stage32.build | 4 | ||||
| -rwxr-xr-x | remote/setup_target | 18 |
9 files changed, 18 insertions, 31 deletions
diff --git a/remote/modules/kdm/data/etc/tmpfiles.d/kdm.conf b/remote/modules/kdm/data/etc/tmpfiles.d/kdm.conf new file mode 100644 index 00000000..64f02ed3 --- /dev/null +++ b/remote/modules/kdm/data/etc/tmpfiles.d/kdm.conf @@ -0,0 +1,2 @@ +D /var/run/kdm 0755 root root + diff --git a/remote/modules/kdm/kdm.build b/remote/modules/kdm/kdm.build index b5d1be08..feac30cb 100644 --- a/remote/modules/kdm/kdm.build +++ b/remote/modules/kdm/kdm.build @@ -16,7 +16,6 @@ build () { post_copy() { #create static kdm folders in stage3.2 mkdir -p "${TARGET_BUILD_DIR}/var/lib/kdm" - mkdir -p "${TARGET_BUILD_DIR}/var/run/kdm" # link kdm config as opensuse wants in in another place ln -s "/etc/kde4" "$TARGET_BUILD_DIR/usr/share/kde4/config" diff --git a/remote/modules/pam/data/etc/tmpfiles.d/pipefs.conf b/remote/modules/pam/data/etc/tmpfiles.d/pipefs.conf new file mode 100644 index 00000000..7c422623 --- /dev/null +++ b/remote/modules/pam/data/etc/tmpfiles.d/pipefs.conf @@ -0,0 +1,2 @@ +D /var/run/rpc_pipefs 0755 root root + diff --git a/remote/modules/pam/pam.build b/remote/modules/pam/pam.build index 063c0065..34319ce8 100644 --- a/remote/modules/pam/pam.build +++ b/remote/modules/pam/pam.build @@ -23,18 +23,5 @@ build() { } post_copy() { - if [ ! -d "${TARGET_BUILD_DIR}/run/rpc_pipefs" ]; then - mkdir -p "${TARGET_BUILD_DIR}/run/rpc_pipefs" || pwarning "Could not mkdir ${TARGET_BUILD_DIR}/run/rpc_pipefs" - fi - - # find libnfsidmap run-time library directory - #local COPYLIST="$MODULE_BUILD_DIR/list_packet_files" - #local SEARCH=$(grep "/libsnfsidmap/" "$COPYLIST" | head -1) - #[ -z "$SEARCH" ] && perror "Hä" - #SEARCH=$(dirname "$SEARCH") - #if [ -d "${SEARCH}" ]; then - # tarcopy "${SEARCH}" "${TARGET_BUILD_DIR}" || pinfo "Something went wrong copying $SEARCH" - #fi - - + : } diff --git a/remote/modules/plymouth/data/etc/tmpfiles.d/plymouth.conf b/remote/modules/plymouth/data/etc/tmpfiles.d/plymouth.conf new file mode 100644 index 00000000..211c61f6 --- /dev/null +++ b/remote/modules/plymouth/data/etc/tmpfiles.d/plymouth.conf @@ -0,0 +1,2 @@ +D /var/run/plymouth 0755 root root + diff --git a/remote/modules/plymouth/plymouth.conf b/remote/modules/plymouth/plymouth.conf index 26e123e4..ec6f8571 100644 --- a/remote/modules/plymouth/plymouth.conf +++ b/remote/modules/plymouth/plymouth.conf @@ -9,5 +9,6 @@ REQUIRED_DIRECTORIES=" /etc /lib /sbin - /var + /var/lib + /var/spool " diff --git a/remote/modules/sshd/data/etc/tmpfiles.d/sshd.conf b/remote/modules/sshd/data/etc/tmpfiles.d/sshd.conf new file mode 100644 index 00000000..d4aa9a67 --- /dev/null +++ b/remote/modules/sshd/data/etc/tmpfiles.d/sshd.conf @@ -0,0 +1,2 @@ +D /var/run/sshd 0755 root root + diff --git a/remote/rootfs/rootfs-stage32/rootfs-stage32.build b/remote/rootfs/rootfs-stage32/rootfs-stage32.build index f9749740..99cb86f7 100644 --- a/remote/rootfs/rootfs-stage32/rootfs-stage32.build +++ b/remote/rootfs/rootfs-stage32/rootfs-stage32.build @@ -65,7 +65,9 @@ post_copy() { [ ! -e "$TARGET_BUILD_DIR/bin/mount" ] && ln -s /usr/bin/mount "$TARGET_BUILD_DIR/bin/mount" # make basic directory structure - mkdir -p "${TARGET_BUILD_DIR}"/{bin,dev,proc,lib,etc,mnt,sys,var/run,var/lock,var/log,run/lock,run/shm,opt/openslx/mnt} + mkdir -p "$TARGET_BUILD_DIR"/{bin,dev,proc,lib,etc,mnt,sys,var,opt/openslx/mnt} + ln -sf "/run/lock" "$TARGET_BUILD_DIR/var/lock" + ln -sf "/run" "$TARGET_BUILD_DIR/var/run" # make openslx log directory mkdir -p "${TARGET_BUILD_DIR}"/var/log/openslx diff --git a/remote/setup_target b/remote/setup_target index 8160de3e..1b857eda 100755 --- a/remote/setup_target +++ b/remote/setup_target @@ -362,6 +362,10 @@ process_module() { copy_static_data pinfo "## Post copy" post_copy + # Sanity checks + [ -e "$TARGET_BUILD_DIR/var/run" -a ! -L "$TARGET_BUILD_DIR/var/run" ] && perror "Messup datected: $TARGET_BUILD_DIR/var/run exists and is not a symlink!" + [ -e "$TARGET_BUILD_DIR/var/lock" -a ! -L "$TARGET_BUILD_DIR/var/lock" ] && perror "Messup datected: $TARGET_BUILD_DIR/var/lock exists and is not a symlink!" + [ -n "$(ls -A "$TARGET_BUILD_DIR/run")" ] && perror "Messup detected: $TARGET_BUILD_DIR/run is not empty. You cannot place static files there, use /etc/tmpfiles.d instead!" # set MODULE_BUILD_SIZE calc_size pinfo "Module completed. Total size: ${MODULE_BUILD_SIZE}" @@ -408,20 +412,6 @@ post_process_target() { ldconfig -v -r "${TARGET_BUILD_DIR}" -f "/ldconf-temp" unlink "$LDTEMP" - # Hacky way of making sure /run and /var/run are actually the same directory - local DIR_RUN="$TARGET_BUILD_DIR/run" - local DIR_VAR_RUN="$TARGET_BUILD_DIR/var/run" - [ -L "$DIR_RUN" ] && perror "$DIR_RUN is a symbolic link, refusing to work!" - if [ -d "$DIR_RUN" -o -d "$DIR_VAR_RUN" ]; then - mkdir -p "$DIR_RUN" || perror "Could not create $DIR_RUN" - if [ -d "$DIR_VAR_RUN" -a ! -L "$DIR_VAR_RUN" ]; then - mv "$DIR_VAR_RUN/"* "$DIR_RUN/" || perror "Could not move contents of $DIR_VAR_RUN to $DIR_RUN" - rmdir "$DIR_VAR_RUN" || perror "Could not delete $DIR_VAR_RUN after moving contents to $DIR_RUN" - fi - if [ ! -L "$DIR_VAR_RUN" ]; then - ln -sf "../run" "$DIR_VAR_RUN" || perror "Could not create symbolic link $DIR_VAR_RUN to ../run" - fi - fi } clean_modules() { |
