### this file is sourced not run
PKGVER=1.0
PKGBUILD=1
PKGARCH=noarch

# source: james
TARBALL=cursor-redhat9.tar.gz
MD5SUM=3467b6ed34d1122f203f50042314b1f2
#SRC_URL="https://store.kde.org/p/999681/startdownload?file_id=1460734691&file_name=5600-redhat9cursor.tar.gz&file_type=application/x-gzip&file_size=120138&url=https%3A%2F%2Fdl.opendesktop.org%2Fapi%2Ffiles%2Fdownload%2Fid%2F1460734691%2Fs%2F19088b92a52c0480e275eea06ccce301%2Ft%2F1538167308%2Fu%2F%2F5600-redhat9cursor.tar.gz"
SRC_URL=http://distro.ibiblio.org/fatdog/source/800/$TARBALL # origina source URL changes too often, use our copy instead
BUNDLE=

CURSOR_PATH=/usr/share/icons
CURSOR_NAME=redhat9

SLACKREQ=
SLACKDESC="cursor-$CURSOR_NAME: cursor-$CURSOR_NAME $PKGVER (Cursor theme)
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME: $CURSOR_NAME cursor theme - from the obvious source.
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME: https://store.kde.org/content/show.php?content=5600
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME: Missing COPY, MOVE, ALIAS, C_HAND, O_HAND, 
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME: 
cursor-$CURSOR_NAME:
"

### standard pkg_download
### standard pkg_prepare
### standard pkg_package

pkg_build() { 
	mkdir -p $CURSOR_PATH/$CURSOR_NAME &&
	cd /tmp &&
	find cursors -xtype l -delete && # remove broken links
	cp -r cursors $CURSOR_PATH/$CURSOR_NAME &&
	cat >> $CURSOR_PATH/$CURSOR_NAME/index.theme << EOF &&
[Icon Theme]
Name=Redhat9 Cursors
Comment=Red Hat Linux 9 black shadow cursor 
Inherits=core
EOF
    # fix missing symlinks
    cd $CURSOR_PATH/$CURSOR_NAME/cursors &&
    bash /tmp/pkg/fix_cursor_theme.sh &&

	# remove missing symlinks
	find . -xtype l -delete && # remove broken links

	pkg_build_slackdesc
}
