#!/bin/sh # Copyright 2010-2012 Robby Workman, Northport, Alabama, USA # All rights reserved. # flash-player-plugin.SlackBuild is free software; you can redistribute it and/or modify it under the # terms of the GNU General Public License as published by the Free Software # Foundation; either version 2 of the License, or any later version. # # flash-player-plugin.SlackBuild is distributed in the hope that it will be useful, but WITHOUT ANY # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR # A PARTICULAR PURPOSE. See the GNU General Public License for more details. # # You should have received a copy of the GNU General Public License along with # this program; if not, write to the Free Software Foundation, Inc., 59 Temple # Place - Suite 330, Boston, MA 02111-1307, USA # # default settings PACKAGE="flash-player-plugin" PACKAGE_EXT="gz" VERSION=${VERSION:=31.0.0.108} BUILD=${BUILD:=1} POPT="-O3" if [ -f ~/.slackbuildrc ]; then . ~/.slackbuildrc elif [ -f ../../runtime/slackbuildrc ]; then . ../../runtime/slackbuildrc fi VERS_MAJ=$(printf $VERSION | cut -d. -f1) case "$( uname -m )" in i?86) ARCH=i386 ;; arm*) ARCH=arm ;; *) ARCH=$( uname -m ) ;; esac SRC="flash_player_npapi_linux.${ARCH}.tar.gz" URL="https://fpdownload.adobe.com/get/flashplayer/pdc/${VERSION}/${SRC}" get_source $SRC $URL tar xfz $CWD/${SRC} -C $PKG # Versie in strings is 24,0,0,186 dus texten met comma's #if ! strings $PKG/libflashplayer.so | grep -wq "^${VERSION}$" 2>/dev/null ; then # printf "\n\tThis script is written for version $VERSION of the plugin,\n" # printf "\tbut you don't seem to have that version. This is likely\n" # printf "\tokay, and it's almost surely not your fault - Adobe tends\n" # printf "\tto release new tarballs without changing the name.\n\n" # sleep 10 #fi mkdir -p $PKG/usr/lib${LIBDIRSUFFIX}/mozilla/plugins mv $PKG/libflashplayer.so $PKG/usr/lib${LIBDIRSUFFIX}/mozilla/plugins mkdir -p $DOCS mv $PKG/readme.txt $DOCS mv $PKG/license.pdf $DOCS mv $PKG/LGPL/* $DOCS rmdir $PKG/LGPL # Fix ownerships chown -R root:root $PKG/usr chmod -R g-w $PKG/usr fixup_package $PKG # Clean up the extra stuff: set +u if [ "$1" = "--cleanup" ]; then rm -rf $TMP/$PACKAGE-$VERSION rm -rf $PKG fi