12ace9
#!/bin/sh -efu
12ace9
# Force creating of DSO symlinks.
12ace9
12ace9
# If using normal root, avoid changing anything.
12ace9
if [ -z "$RPM_BUILD_ROOT" -o "$RPM_BUILD_ROOT" = "/" ]; then
12ace9
  exit 0
12ace9
fi
12ace9
98ffd5
# Create an empty config file for ldconfig to shut up a warning
98ffd5
config=$(mktemp -p "$RPM_BUILD_ROOT")
98ffd5
/sbin/ldconfig -f $(basename "$config") -N -r "$RPM_BUILD_ROOT"
98ffd5
rm -f "$config"
12ace9
# TODO: warn if it created new symlinks and guide people.