Solution to blank screen with google webdesigner on Mageia5?

This forum is dedicated to basic help and support :

Ask here your questions about basic installation and usage of Mageia. For example you may post here all your questions about getting Mageia isos and installing it, configuring your printer, using your word processor etc.

Try to ask your questions in the right sub-forum with as much details as you can gather. the more precise the question will be, the more likely you are to get a useful answer

Solution to blank screen with google webdesigner on Mageia5?

Postby mianrosu » Apr 9th, '16, 06:51

Greetings, nice day for everyone, I'm a fan of web development applications with the characteristic to be wysiwyg type, like BlueGriffon, DW... In fact, I recently move on from win7 to Linux and I choose Mageia, so I'm not an advance user, ok to the point...

I installed Google Web Designer on my Mageia 5 installation, and save the terminal install log to explain this more simple:

Code: Select all
[root@localhost Downloads]# urpmi google-webdesigner_current_i386.rpm

installing google-webdesigner_current_i386.rpm
Preparing...                    #############################################
      1/1: google-webdesigner    #############################################
touch: can not make `touch' on «/root/.local/share/applications/mimeapps.list»: There is no file or directory
/bin/xdg-mime: línea 832: /root/.local/share/applications/mimeapps.list.new: There is no file or directory

(gconftool-2:8338): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: The D-Bus daemon is not running


(gconftool-2:8339): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: The D-Bus daemon is not running


(gconftool-2:8340): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: The D-Bus daemon is not running

Redirecting to /bin/systemctl start atd.service
[root@localhost Downloads]#


I concentrate on the 'touch' problem i think, the installation have this initial problem and i don't know, maybe 'cause this all of the problem with daemon D-Bus started on running installation, but, don't care too much about that, as you can see, the installation never stop, it just install the app as there were any problem... More interesting, you can execute the app on terminal:

Code: Select all
[root@localhost /]# google-webdesigner
which: no google-chrome in (/usr/local/sbin:/usr/sbin:/usr/local/bin:/usr/bin:/usr/lib/qt4/bin:/usr/lib/qt5/bin)


Yep, i'm no fan of google apps, i don't trust to much google either but, come on, a freeware alternative which pretend to compete with (nearly all powerful) Adobe Dreamweaver need to be check and tested, besides, this one looks promising even for just a Beta release full of bugs... Ok, now after execution, it show that on terminal, believe me when i tell you, it just no do that if you don't have google chrome installed, besides that message, it is another one with opera web browser if you don't have it installed before...

There is one more thing, i'm using a laptop acer aspire 4935 32bit... i'm telling you this to save you the comment to install google chrome, there is no more for 32bit users, less pepper... but for some reason this app (Google Web Designer) come for 32bit linux users (cosmic facepalm), not for all distros, but is better than nothing, so... "ddging" (duckduckgo + ing) the problem i find this:

Hi GWD Community,

We've just released a fix for the black screen issue on GWD supported versions. Please take a look at our release notes for more information.

Note:

If the problem persists, close Google Web Designer, delete the following folder, and relaunch:

Windows: HD:\Users\<username>\AppData\Local\Google\Google Web Designer\data\cache(note: you need to enable “Show hidden files, folders, and drives” in Folder options View tab)
Linux: ~/.local/share/google-web-designer/data/cache
Mac: /Users/<username>/Library/Application Support/Google/Web Designer/data/cache

thx!

jaz

Jasmine Rogers

Program Manager, GWD


That message was posted on groups google forums. If i tried to do that?, yes, but i realize (well it's more like i believe) that the directory indicated doesn't exist on Mageia, and if it exist in any other directory of the system, google web designer installation package can't find it as explained before... anyone have ideas how to solve this mess, maybe creating this directory with this file manually or i must still wait for a new update to download a new package?.

PD: sorry for my bad english.
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby doktor5000 » Apr 9th, '16, 23:30

Can you please run
Code: Select all
rpm -qp --scripts --triggers ./google-webdesigner_current_i386.rpm
in the folder where you downloaded the package and post the output here please?
That file it's trying to create is only for associationing webdesigner with any files, to open them weith webdesigner automatically when you try to open them.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18056
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 10th, '16, 02:43

doktor5000 wrote:Can you please run
Code: Select all
rpm -qp --scripts --triggers ./google-webdesigner_current_i386.rpm
in the folder where you downloaded the package and post the output here please?
That file it's trying to create is only for associationing webdesigner with any files, to open them weith webdesigner automatically when you try to open them.


This is the result, i did this with google web designer installed:

Note: I'm using a Mageia 5 installation in spanish, for a virgin copy & paste to the support, if you need translation just tell me.

Code: Select all
    return
  fi

  # Split key-value pair out of MimeType= line from the .desktop file,
  # then split semicolon-separated list of mime types (they should not contain
  # spaces).
  mime_types="$(grep MimeType= /usr/share/applications/${1} |
                cut -d '=' -f 2- |
                tr ';' ' ')"
  for mime_type in ${mime_types}; do
    if egrep -q "^${mime_type}=" "${DEFAULTS_FILE}"; then
      if ! egrep -q "^${mime_type}=.*${1}" "${DEFAULTS_FILE}"; then
        default_apps="$(grep ${mime_type}= "${DEFAULTS_FILE}" |
                        cut -d '=' -f 2-)"
        egrep -v "^${mime_type}=" "${DEFAULTS_FILE}" > "${DEFAULTS_FILE}.new"
        echo "${mime_type}=${default_apps};${1}" >> "${DEFAULTS_FILE}.new"
        mv "${DEFAULTS_FILE}.new" "${DEFAULTS_FILE}"
      fi
    else
      # If there's no mention of the mime type in the file, add it.
      echo "${mime_type}=${1};" >> "${DEFAULTS_FILE}"
    fi
  done
}

update_defaults_list "google-webdesigner.desktop"

# This function uses sed to insert the contents of one file into another file,
# after the first line matching a given regular expression. If there is no
# matching line, then the file is unchanged.
insert_after_first_match() {
  # $1: file to update
  # $2: regular expression
  # $3: file to insert
  sed -i -e "1,/$2/ {
    /$2/ r $3
    }" "$1"
}

# If /usr/share/gnome-control-center/gnome-default-applications.xml exists, it
# may need to be updated to add ourselves to the default applications list. If
# we find the file and it does not seem to contain our patch already (the patch
# is safe to leave even after uninstall), update it.
GNOME_DFL_APPS=/usr/share/gnome-control-center/gnome-default-applications.xml
if [ -f "$GNOME_DFL_APPS" ]; then
# Conditionally insert the contents of the file "default-app-block" after the
# first "<web-browsers>" line we find in gnome-default-applications.xml
  fgrep -q "" "$GNOME_DFL_APPS" || insert_after_first_match \
    "$GNOME_DFL_APPS" \
    "^[    ]*<web-browsers>[    ]*$" \
    "/opt/google/webdesigner/default-app-block"
fi

# RPM repository management scripts for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/rpm.include
# All modifications for GWD are marked with a comment.
#
# GWD Modification
#   Updated include path as variables.include is located in the common folder
#    for GWD.
# Shared variable script for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/variables.include
# All modifications for GWD are marked with a comment.
#
# System-wide package configuration.
DEFAULTS_FILE="/etc/default/google-webdesigner"

# sources.list setting for google-webdesigner updates.
REPOCONFIG="http://dl.google.com/linux/webdesigner/rpm/stable"

# Install the repository signing key (see also:
# http://www.google.com/linuxrepositories/aboutkey.html)
install_rpm_key() {
  # Check to see if key already exists.
  rpm -q gpg-pubkey-7fac5991-4615767f > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi
  # This is to work around a bug in RPM 4.7.0. (see http://crbug.com/22312)
  rpm -q gpg-pubkey-7fac5991-45f06f46 > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi

  # RPM on Mandriva 2009 is dumb and does not understand "rpm --import -"
  TMPKEY=$(mktemp /tmp/google.sig.XXXXXX)
  if [ -n "$TMPKEY" ]; then
    cat > "$TMPKEY" <<KEYDATA
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.2.2 (GNU/Linux)

mQGiBEXwb0YRBADQva2NLpYXxgjNkbuP0LnPoEXruGmvi3XMIxjEUFuGNCP4Rj/a
kv2E5VixBP1vcQFDRJ+p1puh8NU0XERlhpyZrVMzzS/RdWdyXf7E5S8oqNXsoD1z
fvmI+i9b2EhHAA19Kgw7ifV8vMa4tkwslEmcTiwiw8lyUl28Wh4Et8SxzwCggDcA
feGqtn3PP5YAdD0km4S4XeMEAJjlrqPoPv2Gf//tfznY2UyS9PUqFCPLHgFLe80u
QhI2U5jt6jUKN4fHauvR6z3seSAsh1YyzyZCKxJFEKXCCqnrFSoh4WSJsbFNc4PN
b0V0SqiTCkWADZyLT5wll8sWuQ5ylTf3z1ENoHf+G3um3/wk/+xmEHvj9HCTBEXP
78X0A/0Tqlhc2RBnEf+AqxWvM8sk8LzJI/XGjwBvKfXe+l3rnSR2kEAvGzj5Sg0X
4XmfTg4Jl8BNjWyvm2Wmjfet41LPmYJKsux3g0b8yzQxeOA4pQKKAU3Z4+rgzGmf
HdwCG5MNT2A5XxD/eDd+L4fRx0HbFkIQoAi1J3YWQSiTk15fw7RMR29vZ2xlLCBJ
bmMuIExpbnV4IFBhY2thZ2UgU2lnbmluZyBLZXkgPGxpbnV4LXBhY2thZ2VzLWtl
eW1hc3RlckBnb29nbGUuY29tPohjBBMRAgAjAhsDBgsJCAcDAgQVAggDBBYCAwEC
HgECF4AFAkYVdn8CGQEACgkQoECDD3+sWZHKSgCfdq3HtNYJLv+XZleb6HN4zOcF
AJEAniSFbuv8V5FSHxeRimHx25671az+uQINBEXwb0sQCACuA8HT2nr+FM5y/kzI
A51ZcC46KFtIDgjQJ31Q3OrkYP8LbxOpKMRIzvOZrsjOlFmDVqitiVc7qj3lYp6U
rgNVaFv6Qu4bo2/ctjNHDDBdv6nufmusJUWq/9TwieepM/cwnXd+HMxu1XBKRVk9
XyAZ9SvfcW4EtxVgysI+XlptKFa5JCqFM3qJllVohMmr7lMwO8+sxTWTXqxsptJo
pZeKz+UBEEqPyw7CUIVYGC9ENEtIMFvAvPqnhj1GS96REMpry+5s9WKuLEaclWpd
K3krttbDlY1NaeQUCRvBYZ8iAG9YSLHUHMTuI2oea07Rh4dtIAqPwAX8xn36JAYG
2vgLAAMFB/wKqaycjWAZwIe98Yt0qHsdkpmIbarD9fGiA6kfkK/UxjL/k7tmS4Vm
CljrrDZkPSQ/19mpdRcGXtb0NI9+nyM5trweTvtPw+HPkDiJlTaiCcx+izg79Fj9
KcofuNb3lPdXZb9tzf5oDnmm/B+4vkeTuEZJ//IFty8cmvCpzvY+DAz1Vo9rA+Zn
cpWY1n6z6oSS9AsyT/IFlWWBZZ17SpMHu+h4Bxy62+AbPHKGSujEGQhWq8ZRoJAT
G0KSObnmZ7FwFWu1e9XFoUCt0bSjiJWTIyaObMrWu/LvJ3e9I87HseSJStfw6fki
5og9qFEkMrIrBCp3QGuQWBq/rTdMuwNFiEkEGBECAAkFAkXwb0sCGwwACgkQoECD
D3+sWZF/WACfeNAu1/1hwZtUo1bR+MWiCjpvHtwAnA1R3IHqFLQ2X3xJ40XPuAyY
/FJG
=Quqp
-----END PGP PUBLIC KEY BLOCK-----
KEYDATA
    rpm --import "$TMPKEY"
    rc=$?
    rm -f "$TMPKEY"
    if [ "$rc" -eq "0" ]; then
      return 0
    fi
  fi
  return 1
}

determine_rpm_package_manager() {
  local RELEASE
  LSB_RELEASE="$(which lsb_release 2> /dev/null)"
  if [ -x "$LSB_RELEASE" ]; then
    RELEASE=$(lsb_release -i 2> /dev/null | sed 's/:\t/:/' | cut -d ':' -f 2-)
    case $RELEASE in
    "Fedora")
      PACKAGEMANAGER=yum
      ;;
    "MandrivaLinux")
      PACKAGEMANAGER=urpmi
      ;;
    "SUSE LINUX")
      PACKAGEMANAGER=yast
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  # Fallback methods that are probably unnecessary on modern systems.
  if [ -f "/etc/lsb-release" ]; then
    # file missing on Fedora, does not contain DISTRIB_ID on OpenSUSE.
    eval $(sed -e '/DISTRIB_ID/!d' /etc/lsb-release)
    case $DISTRIB_ID in
    MandrivaLinux)
      PACKAGEMANAGER=urpmi
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  if [ -f "/etc/fedora-release" ] || [ -f "/etc/redhat-release" ]; then
    PACKAGEMANAGER=yum
  elif [ -f "/etc/SuSE-release" ]; then
    PACKAGEMANAGER=yast
  elif [ -f "/etc/mandriva-release" ]; then
    PACKAGEMANAGER=urpmi
  fi
}

DEFAULT_ARCH="i386"
YUM_REPO_FILE="/etc/yum.repos.d/google-webdesigner.repo"
ZYPPER_REPO_FILE="/etc/zypp/repos.d/google-webdesigner.repo"
URPMI_REPO_FILE="/etc/urpmi/urpmi.cfg"

install_yum() {
  install_rpm_key

  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  if [ -d "/etc/yum.repos.d" ]; then
cat > "$YUM_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
baseurl=$REPOCONFIG/$DEFAULT_ARCH
enabled=1
gpgcheck=1
REPOCONTENT
  fi
}

# This is called by the cron job, rather than in the RPM postinstall.
# We cannot do this during the install when urpmi is running due to
# database locking. We also need to enable the repository, and we can
# only do that while we are online.
# see: https://qa.mandriva.com/show_bug.cgi?id=31893
configure_urpmi() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  urpmq --list-media | grep -q -s "^google-webdesigner$"
  if [ "$?" -eq "0" ]; then
    # Repository already configured
    return 0
  fi
  urpmi.addmedia --update \
    "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_urpmi() {
  # urpmi not smart enough to pull media_info/pubkey from the repository?
  install_rpm_key

  # Defer urpmi.addmedia to configure_urpmi() in the cron job.
  # See comment there.
  #
  # urpmi.addmedia --update \
  #   "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_yast() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  # We defer adding the key to later. See comment in the cron job.

  # Ideally, we would run: zypper addrepo -t YUM -f \
  # "$REPOCONFIG/$DEFAULT_ARCH" "google-webdesigner"
  # but that does not work when zypper is running.
  if [ -d "/etc/zypp/repos.d" ]; then
cat > "$ZYPPER_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
enabled=1
autorefresh=1
baseurl=$REPOCONFIG/$DEFAULT_ARCH
type=rpm-md
keeppackages=0
REPOCONTENT
  fi
}

# Check if the automatic repository configuration is done, so we know when to
# stop trying.
verify_install() {
  # It's probably enough to see that the repo configs have been created. If they
  # aren't configured properly, update_bad_repo should catch that when it's run.
  case $1 in
  "yum")
    [ -f "$YUM_REPO_FILE" ]
    ;;
  "yast")
    [ -f "$ZYPPER_REPO_FILE" ]
    ;;
  "urpmi")
    urpmq --list-url | grep -q -s "\bgoogle-webdesigner\b"
    ;;
  esac
}

# Update the Google repository if it's not set correctly.
update_bad_repo() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    update_repo_file "$YUM_REPO_FILE"
    ;;
  "yast")
    update_repo_file "$ZYPPER_REPO_FILE"
    ;;
  "urpmi")
    update_urpmi_cfg
    ;;
  esac
}

update_repo_file() {
  REPO_FILE="$1"

  # Don't do anything if the file isn't there, since that probably means the
  # user disabled it.
  if [ ! -r "$REPO_FILE" ]; then
    return 0
  fi

  # Check if the correct repository configuration is in there.
  REPOMATCH=$(grep "^baseurl=$REPOCONFIG/$DEFAULT_ARCH" "$REPO_FILE" \
    2>/dev/null)
  # If it's there, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Check if it's there but disabled by commenting out (as opposed to using the
  # 'enabled' setting).
  MATCH_DISABLED=$(grep "^[[:space:]]*#.*baseurl=$REPOCONFIG/$DEFAULT_ARCH" \
    "$REPO_FILE" 2>/dev/null)
  if [ "$MATCH_DISABLED" ]; then
    # It's OK for it to be disabled, as long as nothing bogus is enabled in its
    # place.
    ACTIVECONFIGS=$(grep "^baseurl=.*" "$REPO_FILE" 2>/dev/null)
    if [ ! "$ACTIVECONFIGS" ]; then
      return 0
    fi
  fi

  # If we get here, the correct repository wasn't found, or something else is
  # active, so fix it. This assumes there is a 'baseurl' setting, but if not,
  # then that's just another way of disabling, so we won't try to add it.
  sed -i -e "s,^baseurl=.*,baseurl=$REPOCONFIG/$DEFAULT_ARCH," "$REPO_FILE"
}

update_urpmi_cfg() {
  REPOCFG=$(urpmq --list-url | grep "\bgoogle-webdesigner\b")
  if [ ! "$REPOCFG" ]; then
    # Don't do anything if the repo isn't there, since that probably means the
    # user deleted it.
    return 0
  fi

  # See if it's the right repo URL
  REPOMATCH=$(echo "$REPOCFG" | grep "\b$REPOCONFIG/$DEFAULT_ARCH\b")
  # If so, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Looks like it's the wrong URL, so recreate it.
  urpmi.removemedia "google-webdesigner" && \
    urpmi.addmedia --update "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

# We only remove the repository configuration during a purge. Since RPM has
# no equivalent to dpkg --purge, the code below is actually never used. We
# keep it only for reference purposes, should we ever need it.
#
#remove_yum() {
#  rm -f "$YUM_REPO_FILE"
#}
#
#remove_urpmi() {
#  # Ideally, we would run: urpmi.removemedia "google-webdesigner"
#  # but that does not work when urpmi is running.
#  # Sentinel comment text does not work either because urpmi.update removes
#  # all comments. So we just delete the entry that matches what we originally
#  # inserted. If such an entry was added manually, that's tough luck.
#  if [ -f "$URPMI_REPO_FILE" ]; then
#    sed -i '\_^google-webdesigner $REPOCONFIG/$DEFAULT_ARCH {$_,/^}$/d' "$URPMI_REPO_FILE"
#  fi
#}
#
#remove_yast() {
#  # Ideally, we would run: zypper removerepo "google-webdesigner"
#  # but that does not work when zypper is running.
#  rm -f /etc/zypp/repos.d/google-webdesigner.repo
#}

DEFAULT_ARCH="i386"

get_lib_dir() {
  if [ "$DEFAULT_ARCH" = "i386" ]; then
    LIBDIR=lib
  elif [ "$DEFAULT_ARCH" = "x86_64" ]; then
    LIBDIR=lib64
  else
    echo Unknown CPU Architecture: "$DEFAULT_ARCH"
    exit 1
  fi
}

# Symlink add/remove scripts for package installation/removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/symlinks.include
# All modifications for GWD are marked with a comment.
#

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary since GWD
#   has no dependence on the NSS libraries.
#
#  NSS_FILES="libnspr4.so.0d libplds4.so.0d libplc4.so.0d libssl3.so.1d \
#     libnss3.so.1d libsmime3.so.1d libnssutil3.so.1d"

# add_nss_symlinks() {
#   get_lib_dir
#   for f in $NSS_FILES
#   do
#     target=$(echo $f | sed 's/\.[01]d$//')
#     if [ -f "/$LIBDIR/$target" ]; then
#       ln -snf "/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     elif [ -f "/usr/$LIBDIR/$target" ]; then
#       ln -snf "/usr/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     else
#       echo $f not found in "/$LIBDIR/$target" or "/usr/$LIBDIR/$target".
#       exit 1
#     fi
#   done
# }

# remove_nss_symlinks() {
#   for f in $NSS_FILES
#   do
#     rm -rf "/opt/google/webdesigner/$f"
#   done
# }

# Fedora 18 now has libudev.so.1. http://crbug.com/145160
# Same for Ubuntu 13.04. http://crbug.com/226002
LIBUDEV_0=libudev.so.0
LIBUDEV_1=libudev.so.1

add_udev_symlinks() {
  get_lib_dir
  if [ -f "/$LIBDIR/$LIBUDEV_0" -o -f "/usr/$LIBDIR/$LIBUDEV_0" -o -f "/lib/$LIBUDEV_0" ]; then
    return 0
  fi

  if [ -f "/$LIBDIR/$LIBUDEV_1" ]; then
    ln -snf "/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  elif [ -f "/usr/$LIBDIR/$LIBUDEV_1" ];
  then
    ln -snf "/usr/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  else
    echo "$LIBUDEV_1" not found in "$LIBDIR" or "/usr/$LIBDIR".
    exit 1
  fi
}

remove_udev_symlinks() {
  rm -rf "/opt/google/webdesigner/$LIBUDEV_0"
}

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary.
#remove_nss_symlinks
#add_nss_symlinks

remove_udev_symlinks
add_udev_symlinks

DEFAULTS_FILE="/etc/default/google-webdesigner"
if [ ! -e "$DEFAULTS_FILE" ]; then
  echo 'repo_add_once="true"' > "$DEFAULTS_FILE"
fi

. "$DEFAULTS_FILE"

if [ "$repo_add_once" = "true" ]; then
  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    install_yum
    ;;
  "urpmi")
    install_urpmi
    ;;
  "yast")
    install_yast
    ;;
  esac
fi

# Some package managers have locks that prevent everything from being
# configured at install time, so wait a bit then kick the cron job to do
# whatever is left. Probably the db will be unlocked by then, but if not, the
# cron job will keep retrying.
# Do this with 'at' instead of a backgrounded shell because zypper waits on all
# sub-shells to finish before it finishes, which is exactly the opposite of
# what we want here. Also preemptively start atd because for some reason it's
# not always running, which kind of defeats the purpose of having 'at' as a
# required LSB command.
service atd start
echo "sh /etc/cron.daily/google-webdesigner" | at now + 2 minute > /dev/null 2>&1

CHANNEL=stable
# GWD Modification
#   Remove case statement on CHANNEL and set priority to 200 which is the value
#   for Chrome stable.
PRIORITY=200

# GWD Modification
#   Remvoed the update-alternatives call as GWD is not an alternative app that
#   the OS needs to be aware of.
# /usr/sbin/update-alternatives --install /usr/bin/google-webdesigner google-webdesigner \
#   /usr/bin/google-webdesigner $PRIORITY

exit 0

#------------------------------------------------------------------------------
#   Pre uninstallation script
#------------------------------------------------------------------------------
preuninstall scriptlet (using /bin/sh):

# This is copied from:
#   /trunk/src/chrome/installer/linux/rpm/chrome.spec-template
# All modifications for GWD are marked with a comment.

if [ "$1" -eq "0" ]; then
  mode="uninstall"
elif [ "$1" -eq "1" ]; then
  mode="upgrade"
fi

# RPM repository management scripts for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/rpm.include
# All modifications for GWD are marked with a comment.
#
# GWD Modification
#   Updated include path as variables.include is located in the common folder
#    for GWD.
# Shared variable script for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/variables.include
# All modifications for GWD are marked with a comment.
#
# System-wide package configuration.
DEFAULTS_FILE="/etc/default/google-webdesigner"

# sources.list setting for google-webdesigner updates.
REPOCONFIG="http://dl.google.com/linux/webdesigner/rpm/stable"

# Install the repository signing key (see also:
# http://www.google.com/linuxrepositories/aboutkey.html)
install_rpm_key() {
  # Check to see if key already exists.
  rpm -q gpg-pubkey-7fac5991-4615767f > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi
  # This is to work around a bug in RPM 4.7.0. (see http://crbug.com/22312)
  rpm -q gpg-pubkey-7fac5991-45f06f46 > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi

  # RPM on Mandriva 2009 is dumb and does not understand "rpm --import -"
  TMPKEY=$(mktemp /tmp/google.sig.XXXXXX)
  if [ -n "$TMPKEY" ]; then
    cat > "$TMPKEY" <<KEYDATA
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.2.2 (GNU/Linux)

mQGiBEXwb0YRBADQva2NLpYXxgjNkbuP0LnPoEXruGmvi3XMIxjEUFuGNCP4Rj/a
kv2E5VixBP1vcQFDRJ+p1puh8NU0XERlhpyZrVMzzS/RdWdyXf7E5S8oqNXsoD1z
fvmI+i9b2EhHAA19Kgw7ifV8vMa4tkwslEmcTiwiw8lyUl28Wh4Et8SxzwCggDcA
feGqtn3PP5YAdD0km4S4XeMEAJjlrqPoPv2Gf//tfznY2UyS9PUqFCPLHgFLe80u
QhI2U5jt6jUKN4fHauvR6z3seSAsh1YyzyZCKxJFEKXCCqnrFSoh4WSJsbFNc4PN
b0V0SqiTCkWADZyLT5wll8sWuQ5ylTf3z1ENoHf+G3um3/wk/+xmEHvj9HCTBEXP
78X0A/0Tqlhc2RBnEf+AqxWvM8sk8LzJI/XGjwBvKfXe+l3rnSR2kEAvGzj5Sg0X
4XmfTg4Jl8BNjWyvm2Wmjfet41LPmYJKsux3g0b8yzQxeOA4pQKKAU3Z4+rgzGmf
HdwCG5MNT2A5XxD/eDd+L4fRx0HbFkIQoAi1J3YWQSiTk15fw7RMR29vZ2xlLCBJ
bmMuIExpbnV4IFBhY2thZ2UgU2lnbmluZyBLZXkgPGxpbnV4LXBhY2thZ2VzLWtl
eW1hc3RlckBnb29nbGUuY29tPohjBBMRAgAjAhsDBgsJCAcDAgQVAggDBBYCAwEC
HgECF4AFAkYVdn8CGQEACgkQoECDD3+sWZHKSgCfdq3HtNYJLv+XZleb6HN4zOcF
AJEAniSFbuv8V5FSHxeRimHx25671az+uQINBEXwb0sQCACuA8HT2nr+FM5y/kzI
A51ZcC46KFtIDgjQJ31Q3OrkYP8LbxOpKMRIzvOZrsjOlFmDVqitiVc7qj3lYp6U
rgNVaFv6Qu4bo2/ctjNHDDBdv6nufmusJUWq/9TwieepM/cwnXd+HMxu1XBKRVk9
XyAZ9SvfcW4EtxVgysI+XlptKFa5JCqFM3qJllVohMmr7lMwO8+sxTWTXqxsptJo
pZeKz+UBEEqPyw7CUIVYGC9ENEtIMFvAvPqnhj1GS96REMpry+5s9WKuLEaclWpd
K3krttbDlY1NaeQUCRvBYZ8iAG9YSLHUHMTuI2oea07Rh4dtIAqPwAX8xn36JAYG
2vgLAAMFB/wKqaycjWAZwIe98Yt0qHsdkpmIbarD9fGiA6kfkK/UxjL/k7tmS4Vm
CljrrDZkPSQ/19mpdRcGXtb0NI9+nyM5trweTvtPw+HPkDiJlTaiCcx+izg79Fj9
KcofuNb3lPdXZb9tzf5oDnmm/B+4vkeTuEZJ//IFty8cmvCpzvY+DAz1Vo9rA+Zn
cpWY1n6z6oSS9AsyT/IFlWWBZZ17SpMHu+h4Bxy62+AbPHKGSujEGQhWq8ZRoJAT
G0KSObnmZ7FwFWu1e9XFoUCt0bSjiJWTIyaObMrWu/LvJ3e9I87HseSJStfw6fki
5og9qFEkMrIrBCp3QGuQWBq/rTdMuwNFiEkEGBECAAkFAkXwb0sCGwwACgkQoECD
D3+sWZF/WACfeNAu1/1hwZtUo1bR+MWiCjpvHtwAnA1R3IHqFLQ2X3xJ40XPuAyY
/FJG
=Quqp
-----END PGP PUBLIC KEY BLOCK-----
KEYDATA
    rpm --import "$TMPKEY"
    rc=$?
    rm -f "$TMPKEY"
    if [ "$rc" -eq "0" ]; then
      return 0
    fi
  fi
  return 1
}

determine_rpm_package_manager() {
  local RELEASE
  LSB_RELEASE="$(which lsb_release 2> /dev/null)"
  if [ -x "$LSB_RELEASE" ]; then
    RELEASE=$(lsb_release -i 2> /dev/null | sed 's/:\t/:/' | cut -d ':' -f 2-)
    case $RELEASE in
    "Fedora")
      PACKAGEMANAGER=yum
      ;;
    "MandrivaLinux")
      PACKAGEMANAGER=urpmi
      ;;
    "SUSE LINUX")
      PACKAGEMANAGER=yast
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  # Fallback methods that are probably unnecessary on modern systems.
  if [ -f "/etc/lsb-release" ]; then
    # file missing on Fedora, does not contain DISTRIB_ID on OpenSUSE.
    eval $(sed -e '/DISTRIB_ID/!d' /etc/lsb-release)
    case $DISTRIB_ID in
    MandrivaLinux)
      PACKAGEMANAGER=urpmi
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  if [ -f "/etc/fedora-release" ] || [ -f "/etc/redhat-release" ]; then
    PACKAGEMANAGER=yum
  elif [ -f "/etc/SuSE-release" ]; then
    PACKAGEMANAGER=yast
  elif [ -f "/etc/mandriva-release" ]; then
    PACKAGEMANAGER=urpmi
  fi
}

DEFAULT_ARCH="i386"
YUM_REPO_FILE="/etc/yum.repos.d/google-webdesigner.repo"
ZYPPER_REPO_FILE="/etc/zypp/repos.d/google-webdesigner.repo"
URPMI_REPO_FILE="/etc/urpmi/urpmi.cfg"

install_yum() {
  install_rpm_key

  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  if [ -d "/etc/yum.repos.d" ]; then
cat > "$YUM_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
baseurl=$REPOCONFIG/$DEFAULT_ARCH
enabled=1
gpgcheck=1
REPOCONTENT
  fi
}

# This is called by the cron job, rather than in the RPM postinstall.
# We cannot do this during the install when urpmi is running due to
# database locking. We also need to enable the repository, and we can
# only do that while we are online.
# see: https://qa.mandriva.com/show_bug.cgi?id=31893
configure_urpmi() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  urpmq --list-media | grep -q -s "^google-webdesigner$"
  if [ "$?" -eq "0" ]; then
    # Repository already configured
    return 0
  fi
  urpmi.addmedia --update \
    "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_urpmi() {
  # urpmi not smart enough to pull media_info/pubkey from the repository?
  install_rpm_key

  # Defer urpmi.addmedia to configure_urpmi() in the cron job.
  # See comment there.
  #
  # urpmi.addmedia --update \
  #   "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_yast() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  # We defer adding the key to later. See comment in the cron job.

  # Ideally, we would run: zypper addrepo -t YUM -f \
  # "$REPOCONFIG/$DEFAULT_ARCH" "google-webdesigner"
  # but that does not work when zypper is running.
  if [ -d "/etc/zypp/repos.d" ]; then
cat > "$ZYPPER_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
enabled=1
autorefresh=1
baseurl=$REPOCONFIG/$DEFAULT_ARCH
type=rpm-md
keeppackages=0
REPOCONTENT
  fi
}

# Check if the automatic repository configuration is done, so we know when to
# stop trying.
verify_install() {
  # It's probably enough to see that the repo configs have been created. If they
  # aren't configured properly, update_bad_repo should catch that when it's run.
  case $1 in
  "yum")
    [ -f "$YUM_REPO_FILE" ]
    ;;
  "yast")
    [ -f "$ZYPPER_REPO_FILE" ]
    ;;
  "urpmi")
    urpmq --list-url | grep -q -s "\bgoogle-webdesigner\b"
    ;;
  esac
}

# Update the Google repository if it's not set correctly.
update_bad_repo() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    update_repo_file "$YUM_REPO_FILE"
    ;;
  "yast")
    update_repo_file "$ZYPPER_REPO_FILE"
    ;;
  "urpmi")
    update_urpmi_cfg
    ;;
  esac
}

update_repo_file() {
  REPO_FILE="$1"

  # Don't do anything if the file isn't there, since that probably means the
  # user disabled it.
  if [ ! -r "$REPO_FILE" ]; then
    return 0
  fi

  # Check if the correct repository configuration is in there.
  REPOMATCH=$(grep "^baseurl=$REPOCONFIG/$DEFAULT_ARCH" "$REPO_FILE" \
    2>/dev/null)
  # If it's there, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Check if it's there but disabled by commenting out (as opposed to using the
  # 'enabled' setting).
  MATCH_DISABLED=$(grep "^[[:space:]]*#.*baseurl=$REPOCONFIG/$DEFAULT_ARCH" \
    "$REPO_FILE" 2>/dev/null)
  if [ "$MATCH_DISABLED" ]; then
    # It's OK for it to be disabled, as long as nothing bogus is enabled in its
    # place.
    ACTIVECONFIGS=$(grep "^baseurl=.*" "$REPO_FILE" 2>/dev/null)
    if [ ! "$ACTIVECONFIGS" ]; then
      return 0
    fi
  fi

  # If we get here, the correct repository wasn't found, or something else is
  # active, so fix it. This assumes there is a 'baseurl' setting, but if not,
  # then that's just another way of disabling, so we won't try to add it.
  sed -i -e "s,^baseurl=.*,baseurl=$REPOCONFIG/$DEFAULT_ARCH," "$REPO_FILE"
}

update_urpmi_cfg() {
  REPOCFG=$(urpmq --list-url | grep "\bgoogle-webdesigner\b")
  if [ ! "$REPOCFG" ]; then
    # Don't do anything if the repo isn't there, since that probably means the
    # user deleted it.
    return 0
  fi

  # See if it's the right repo URL
  REPOMATCH=$(echo "$REPOCFG" | grep "\b$REPOCONFIG/$DEFAULT_ARCH\b")
  # If so, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Looks like it's the wrong URL, so recreate it.
  urpmi.removemedia "google-webdesigner" && \
    urpmi.addmedia --update "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

# We only remove the repository configuration during a purge. Since RPM has
# no equivalent to dpkg --purge, the code below is actually never used. We
# keep it only for reference purposes, should we ever need it.
#
#remove_yum() {
#  rm -f "$YUM_REPO_FILE"
#}
#
#remove_urpmi() {
#  # Ideally, we would run: urpmi.removemedia "google-webdesigner"
#  # but that does not work when urpmi is running.
#  # Sentinel comment text does not work either because urpmi.update removes
#  # all comments. So we just delete the entry that matches what we originally
#  # inserted. If such an entry was added manually, that's tough luck.
#  if [ -f "$URPMI_REPO_FILE" ]; then
#    sed -i '\_^google-webdesigner $REPOCONFIG/$DEFAULT_ARCH {$_,/^}$/d' "$URPMI_REPO_FILE"
#  fi
#}
#
#remove_yast() {
#  # Ideally, we would run: zypper removerepo "google-webdesigner"
#  # but that does not work when zypper is running.
#  rm -f /etc/zypp/repos.d/google-webdesigner.repo
#}

DEFAULT_ARCH="i386"

get_lib_dir() {
  if [ "$DEFAULT_ARCH" = "i386" ]; then
    LIBDIR=lib
  elif [ "$DEFAULT_ARCH" = "x86_64" ]; then
    LIBDIR=lib64
  else
    echo Unknown CPU Architecture: "$DEFAULT_ARCH"
    exit 1
  fi
}

# Symlink add/remove scripts for package installation/removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/symlinks.include
# All modifications for GWD are marked with a comment.
#

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary since GWD
#   has no dependence on the NSS libraries.
#
#  NSS_FILES="libnspr4.so.0d libplds4.so.0d libplc4.so.0d libssl3.so.1d \
#     libnss3.so.1d libsmime3.so.1d libnssutil3.so.1d"

# add_nss_symlinks() {
#   get_lib_dir
#   for f in $NSS_FILES
#   do
#     target=$(echo $f | sed 's/\.[01]d$//')
#     if [ -f "/$LIBDIR/$target" ]; then
#       ln -snf "/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     elif [ -f "/usr/$LIBDIR/$target" ]; then
#       ln -snf "/usr/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     else
#       echo $f not found in "/$LIBDIR/$target" or "/usr/$LIBDIR/$target".
#       exit 1
#     fi
#   done
# }

# remove_nss_symlinks() {
#   for f in $NSS_FILES
#   do
#     rm -rf "/opt/google/webdesigner/$f"
#   done
# }

# Fedora 18 now has libudev.so.1. http://crbug.com/145160
# Same for Ubuntu 13.04. http://crbug.com/226002
LIBUDEV_0=libudev.so.0
LIBUDEV_1=libudev.so.1

add_udev_symlinks() {
  get_lib_dir
  if [ -f "/$LIBDIR/$LIBUDEV_0" -o -f "/usr/$LIBDIR/$LIBUDEV_0" -o -f "/lib/$LIBUDEV_0" ]; then
    return 0
  fi

  if [ -f "/$LIBDIR/$LIBUDEV_1" ]; then
    ln -snf "/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  elif [ -f "/usr/$LIBDIR/$LIBUDEV_1" ];
  then
    ln -snf "/usr/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  else
    echo "$LIBUDEV_1" not found in "$LIBDIR" or "/usr/$LIBDIR".
    exit 1
  fi
}

remove_udev_symlinks() {
  rm -rf "/opt/google/webdesigner/$LIBUDEV_0"
}

# Only remove menu items and symlinks on uninstall. When upgrading,
# old_pkg's %preun runs after new_pkg's %post.
if [ "$mode" = "uninstall" ]; then
# Pre remove scripts for package removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/prerm.include
# All modifications for GWD are marked with a comment.
#

# Remove icons from the system icons
XDG_ICON_RESOURCE="`which xdg-icon-resource 2> /dev/null || true`"
if [ ! -x "$XDG_ICON_RESOURCE" ]; then
  echo "Error: Could not find xdg-icon-resource" >&2
  exit 1
fi
# GWD Modification
#   Added /resources/ below as the GWD icons are located in a subdirectory
#   next to the main executable.
for icon in "/opt/google/webdesigner/resources/product_logo_"*.png; do
  size="${icon##*/product_logo_}"
  "$XDG_ICON_RESOURCE" uninstall --size "${size%.png}" "google-webdesigner"
done

UPDATE_MENUS="`which update-menus 2> /dev/null || true`"
if [ -x "$UPDATE_MENUS" ]; then
  update-menus
fi

# GWD Modification
#   Remove our registered custom template protocol.
gconftool-2 --recursive-unset /desktop/gnome/url-handlers/gwd-template

# Update cache of .desktop file MIME types. Non-fatal since it's just a cache.
update-desktop-database || true

# GWD Modification
# Commented out for Web Designer as this shouldn't be necessary.
# remove_nss_symlinks
  remove_udev_symlinks

# GWD Modification
#   Remvoed the update-alternatives call as GWD is not an alternative app that
#   the OS needs to be aware of.
#   /usr/sbin/update-alternatives --remove google-webdesigner \
#     /usr/bin/google-webdesigner
fi

# On Debian we only remove when we purge. However, RPM has no equivalent to
# dpkg --purge, so this is all disabled.
#
#determine_rpm_package_manager
#
#case $PACKAGEMANAGER in
#"yum")
#  remove_yum
#  ;;
#"urpmi")
#  remove_urpmi
#  ;;
#"yast")
#  remove_yast
#  ;;
#esac

exit 0

#------------------------------------------------------------------------------
#   Post uninstallation script
#------------------------------------------------------------------------------
postuninstall scriptlet (using /bin/sh):

exit 0
[root@localhost Descargas]#


That was the entire message as seen in my xfce-terminal, i doubt if it is complete, I uninstall google web designer to do the same procedure as before:

Code: Select all
[root@localhost Descargas]# urpme google-webdesigner
BDB2053 Freeing read locks for locker 0x200f: 13408/3073476352
quitando google-webdesigner-1.2.5.0-1.i386

(gconftool-2:22212): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error al eliminar la asignación recursivamente «/desktop/gnome/url-handlers/gwd-template»: El demonio de D-Bus no está en ejecución


(gconftool-2:22212): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
quitando paquete google-webdesigner-1.2.5.0-1.i386
      1/1: quitando google-webdesigner-1.2.5.0-1.i386
                                 #####################################################################################################################################
[root@localhost Descargas]#
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 10th, '16, 02:45

I'm very sorry for the double post but, i couldn't put together everything in one post, it was more characters than the accepted.

I admit that I create manually a launcher for this app (google web designer), this one i must remove it manually, for reasons beyond my understanding, it still maintain the icon of the app...

Code: Select all
[root@localhost Descargas]# google-webdesigner
bash: google-webdesigner: no se encontró la orden
[root@localhost Descargas]#


Now, i'm doing this with google web designer uninstalled and the launcher mentioned erased:

rpm -qp --scripts --triggers ./google-webdesigner_current_i386.rpm


This is the result:

Code: Select all
update_defaults_list() {
  # $1: name of the .desktop file

  local DEFAULTS_FILE="/usr/share/applications/defaults.list"

  if [ ! -f "${DEFAULTS_FILE}" ]; then
    return
  fi

  # Split key-value pair out of MimeType= line from the .desktop file,
  # then split semicolon-separated list of mime types (they should not contain
  # spaces).
  mime_types="$(grep MimeType= /usr/share/applications/${1} |
                cut -d '=' -f 2- |
                tr ';' ' ')"
  for mime_type in ${mime_types}; do
    if egrep -q "^${mime_type}=" "${DEFAULTS_FILE}"; then
      if ! egrep -q "^${mime_type}=.*${1}" "${DEFAULTS_FILE}"; then
        default_apps="$(grep ${mime_type}= "${DEFAULTS_FILE}" |
                        cut -d '=' -f 2-)"
        egrep -v "^${mime_type}=" "${DEFAULTS_FILE}" > "${DEFAULTS_FILE}.new"
        echo "${mime_type}=${default_apps};${1}" >> "${DEFAULTS_FILE}.new"
        mv "${DEFAULTS_FILE}.new" "${DEFAULTS_FILE}"
      fi
    else
      # If there's no mention of the mime type in the file, add it.
      echo "${mime_type}=${1};" >> "${DEFAULTS_FILE}"
    fi
  done
}

update_defaults_list "google-webdesigner.desktop"

# This function uses sed to insert the contents of one file into another file,
# after the first line matching a given regular expression. If there is no
# matching line, then the file is unchanged.
insert_after_first_match() {
  # $1: file to update
  # $2: regular expression
  # $3: file to insert
  sed -i -e "1,/$2/ {
    /$2/ r $3
    }" "$1"
}

# If /usr/share/gnome-control-center/gnome-default-applications.xml exists, it
# may need to be updated to add ourselves to the default applications list. If
# we find the file and it does not seem to contain our patch already (the patch
# is safe to leave even after uninstall), update it.
GNOME_DFL_APPS=/usr/share/gnome-control-center/gnome-default-applications.xml
if [ -f "$GNOME_DFL_APPS" ]; then
# Conditionally insert the contents of the file "default-app-block" after the
# first "<web-browsers>" line we find in gnome-default-applications.xml
  fgrep -q "" "$GNOME_DFL_APPS" || insert_after_first_match \
    "$GNOME_DFL_APPS" \
    "^[    ]*<web-browsers>[    ]*$" \
    "/opt/google/webdesigner/default-app-block"
fi

# RPM repository management scripts for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/rpm.include
# All modifications for GWD are marked with a comment.
#
# GWD Modification
#   Updated include path as variables.include is located in the common folder
#    for GWD.
# Shared variable script for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/variables.include
# All modifications for GWD are marked with a comment.
#
# System-wide package configuration.
DEFAULTS_FILE="/etc/default/google-webdesigner"

# sources.list setting for google-webdesigner updates.
REPOCONFIG="http://dl.google.com/linux/webdesigner/rpm/stable"

# Install the repository signing key (see also:
# http://www.google.com/linuxrepositories/aboutkey.html)
install_rpm_key() {
  # Check to see if key already exists.
  rpm -q gpg-pubkey-7fac5991-4615767f > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi
  # This is to work around a bug in RPM 4.7.0. (see http://crbug.com/22312)
  rpm -q gpg-pubkey-7fac5991-45f06f46 > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi

  # RPM on Mandriva 2009 is dumb and does not understand "rpm --import -"
  TMPKEY=$(mktemp /tmp/google.sig.XXXXXX)
  if [ -n "$TMPKEY" ]; then
    cat > "$TMPKEY" <<KEYDATA
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.2.2 (GNU/Linux)

mQGiBEXwb0YRBADQva2NLpYXxgjNkbuP0LnPoEXruGmvi3XMIxjEUFuGNCP4Rj/a
kv2E5VixBP1vcQFDRJ+p1puh8NU0XERlhpyZrVMzzS/RdWdyXf7E5S8oqNXsoD1z
fvmI+i9b2EhHAA19Kgw7ifV8vMa4tkwslEmcTiwiw8lyUl28Wh4Et8SxzwCggDcA
feGqtn3PP5YAdD0km4S4XeMEAJjlrqPoPv2Gf//tfznY2UyS9PUqFCPLHgFLe80u
QhI2U5jt6jUKN4fHauvR6z3seSAsh1YyzyZCKxJFEKXCCqnrFSoh4WSJsbFNc4PN
b0V0SqiTCkWADZyLT5wll8sWuQ5ylTf3z1ENoHf+G3um3/wk/+xmEHvj9HCTBEXP
78X0A/0Tqlhc2RBnEf+AqxWvM8sk8LzJI/XGjwBvKfXe+l3rnSR2kEAvGzj5Sg0X
4XmfTg4Jl8BNjWyvm2Wmjfet41LPmYJKsux3g0b8yzQxeOA4pQKKAU3Z4+rgzGmf
HdwCG5MNT2A5XxD/eDd+L4fRx0HbFkIQoAi1J3YWQSiTk15fw7RMR29vZ2xlLCBJ
bmMuIExpbnV4IFBhY2thZ2UgU2lnbmluZyBLZXkgPGxpbnV4LXBhY2thZ2VzLWtl
eW1hc3RlckBnb29nbGUuY29tPohjBBMRAgAjAhsDBgsJCAcDAgQVAggDBBYCAwEC
HgECF4AFAkYVdn8CGQEACgkQoECDD3+sWZHKSgCfdq3HtNYJLv+XZleb6HN4zOcF
AJEAniSFbuv8V5FSHxeRimHx25671az+uQINBEXwb0sQCACuA8HT2nr+FM5y/kzI
A51ZcC46KFtIDgjQJ31Q3OrkYP8LbxOpKMRIzvOZrsjOlFmDVqitiVc7qj3lYp6U
rgNVaFv6Qu4bo2/ctjNHDDBdv6nufmusJUWq/9TwieepM/cwnXd+HMxu1XBKRVk9
XyAZ9SvfcW4EtxVgysI+XlptKFa5JCqFM3qJllVohMmr7lMwO8+sxTWTXqxsptJo
pZeKz+UBEEqPyw7CUIVYGC9ENEtIMFvAvPqnhj1GS96REMpry+5s9WKuLEaclWpd
K3krttbDlY1NaeQUCRvBYZ8iAG9YSLHUHMTuI2oea07Rh4dtIAqPwAX8xn36JAYG
2vgLAAMFB/wKqaycjWAZwIe98Yt0qHsdkpmIbarD9fGiA6kfkK/UxjL/k7tmS4Vm
CljrrDZkPSQ/19mpdRcGXtb0NI9+nyM5trweTvtPw+HPkDiJlTaiCcx+izg79Fj9
KcofuNb3lPdXZb9tzf5oDnmm/B+4vkeTuEZJ//IFty8cmvCpzvY+DAz1Vo9rA+Zn
cpWY1n6z6oSS9AsyT/IFlWWBZZ17SpMHu+h4Bxy62+AbPHKGSujEGQhWq8ZRoJAT
G0KSObnmZ7FwFWu1e9XFoUCt0bSjiJWTIyaObMrWu/LvJ3e9I87HseSJStfw6fki
5og9qFEkMrIrBCp3QGuQWBq/rTdMuwNFiEkEGBECAAkFAkXwb0sCGwwACgkQoECD
D3+sWZF/WACfeNAu1/1hwZtUo1bR+MWiCjpvHtwAnA1R3IHqFLQ2X3xJ40XPuAyY
/FJG
=Quqp
-----END PGP PUBLIC KEY BLOCK-----
KEYDATA
    rpm --import "$TMPKEY"
    rc=$?
    rm -f "$TMPKEY"
    if [ "$rc" -eq "0" ]; then
      return 0
    fi
  fi
  return 1
}

determine_rpm_package_manager() {
  local RELEASE
  LSB_RELEASE="$(which lsb_release 2> /dev/null)"
  if [ -x "$LSB_RELEASE" ]; then
    RELEASE=$(lsb_release -i 2> /dev/null | sed 's/:\t/:/' | cut -d ':' -f 2-)
    case $RELEASE in
    "Fedora")
      PACKAGEMANAGER=yum
      ;;
    "MandrivaLinux")
      PACKAGEMANAGER=urpmi
      ;;
    "SUSE LINUX")
      PACKAGEMANAGER=yast
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  # Fallback methods that are probably unnecessary on modern systems.
  if [ -f "/etc/lsb-release" ]; then
    # file missing on Fedora, does not contain DISTRIB_ID on OpenSUSE.
    eval $(sed -e '/DISTRIB_ID/!d' /etc/lsb-release)
    case $DISTRIB_ID in
    MandrivaLinux)
      PACKAGEMANAGER=urpmi
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  if [ -f "/etc/fedora-release" ] || [ -f "/etc/redhat-release" ]; then
    PACKAGEMANAGER=yum
  elif [ -f "/etc/SuSE-release" ]; then
    PACKAGEMANAGER=yast
  elif [ -f "/etc/mandriva-release" ]; then
    PACKAGEMANAGER=urpmi
  fi
}

DEFAULT_ARCH="i386"
YUM_REPO_FILE="/etc/yum.repos.d/google-webdesigner.repo"
ZYPPER_REPO_FILE="/etc/zypp/repos.d/google-webdesigner.repo"
URPMI_REPO_FILE="/etc/urpmi/urpmi.cfg"

install_yum() {
  install_rpm_key

  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  if [ -d "/etc/yum.repos.d" ]; then
cat > "$YUM_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
baseurl=$REPOCONFIG/$DEFAULT_ARCH
enabled=1
gpgcheck=1
REPOCONTENT
  fi
}

# This is called by the cron job, rather than in the RPM postinstall.
# We cannot do this during the install when urpmi is running due to
# database locking. We also need to enable the repository, and we can
# only do that while we are online.
# see: https://qa.mandriva.com/show_bug.cgi?id=31893
configure_urpmi() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  urpmq --list-media | grep -q -s "^google-webdesigner$"
  if [ "$?" -eq "0" ]; then
    # Repository already configured
    return 0
  fi
  urpmi.addmedia --update \
    "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_urpmi() {
  # urpmi not smart enough to pull media_info/pubkey from the repository?
  install_rpm_key

  # Defer urpmi.addmedia to configure_urpmi() in the cron job.
  # See comment there.
  #
  # urpmi.addmedia --update \
  #   "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_yast() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  # We defer adding the key to later. See comment in the cron job.

  # Ideally, we would run: zypper addrepo -t YUM -f \
  # "$REPOCONFIG/$DEFAULT_ARCH" "google-webdesigner"
  # but that does not work when zypper is running.
  if [ -d "/etc/zypp/repos.d" ]; then
cat > "$ZYPPER_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
enabled=1
autorefresh=1
baseurl=$REPOCONFIG/$DEFAULT_ARCH
type=rpm-md
keeppackages=0
REPOCONTENT
  fi
}

# Check if the automatic repository configuration is done, so we know when to
# stop trying.
verify_install() {
  # It's probably enough to see that the repo configs have been created. If they
  # aren't configured properly, update_bad_repo should catch that when it's run.
  case $1 in
  "yum")
    [ -f "$YUM_REPO_FILE" ]
    ;;
  "yast")
    [ -f "$ZYPPER_REPO_FILE" ]
    ;;
  "urpmi")
    urpmq --list-url | grep -q -s "\bgoogle-webdesigner\b"
    ;;
  esac
}

# Update the Google repository if it's not set correctly.
update_bad_repo() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    update_repo_file "$YUM_REPO_FILE"
    ;;
  "yast")
    update_repo_file "$ZYPPER_REPO_FILE"
    ;;
  "urpmi")
    update_urpmi_cfg
    ;;
  esac
}

update_repo_file() {
  REPO_FILE="$1"

  # Don't do anything if the file isn't there, since that probably means the
  # user disabled it.
  if [ ! -r "$REPO_FILE" ]; then
    return 0
  fi

  # Check if the correct repository configuration is in there.
  REPOMATCH=$(grep "^baseurl=$REPOCONFIG/$DEFAULT_ARCH" "$REPO_FILE" \
    2>/dev/null)
  # If it's there, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Check if it's there but disabled by commenting out (as opposed to using the
  # 'enabled' setting).
  MATCH_DISABLED=$(grep "^[[:space:]]*#.*baseurl=$REPOCONFIG/$DEFAULT_ARCH" \
    "$REPO_FILE" 2>/dev/null)
  if [ "$MATCH_DISABLED" ]; then
    # It's OK for it to be disabled, as long as nothing bogus is enabled in its
    # place.
    ACTIVECONFIGS=$(grep "^baseurl=.*" "$REPO_FILE" 2>/dev/null)
    if [ ! "$ACTIVECONFIGS" ]; then
      return 0
    fi
  fi

  # If we get here, the correct repository wasn't found, or something else is
  # active, so fix it. This assumes there is a 'baseurl' setting, but if not,
  # then that's just another way of disabling, so we won't try to add it.
  sed -i -e "s,^baseurl=.*,baseurl=$REPOCONFIG/$DEFAULT_ARCH," "$REPO_FILE"
}

update_urpmi_cfg() {
  REPOCFG=$(urpmq --list-url | grep "\bgoogle-webdesigner\b")
  if [ ! "$REPOCFG" ]; then
    # Don't do anything if the repo isn't there, since that probably means the
    # user deleted it.
    return 0
  fi

  # See if it's the right repo URL
  REPOMATCH=$(echo "$REPOCFG" | grep "\b$REPOCONFIG/$DEFAULT_ARCH\b")
  # If so, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Looks like it's the wrong URL, so recreate it.
  urpmi.removemedia "google-webdesigner" && \
    urpmi.addmedia --update "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

# We only remove the repository configuration during a purge. Since RPM has
# no equivalent to dpkg --purge, the code below is actually never used. We
# keep it only for reference purposes, should we ever need it.
#
#remove_yum() {
#  rm -f "$YUM_REPO_FILE"
#}
#
#remove_urpmi() {
#  # Ideally, we would run: urpmi.removemedia "google-webdesigner"
#  # but that does not work when urpmi is running.
#  # Sentinel comment text does not work either because urpmi.update removes
#  # all comments. So we just delete the entry that matches what we originally
#  # inserted. If such an entry was added manually, that's tough luck.
#  if [ -f "$URPMI_REPO_FILE" ]; then
#    sed -i '\_^google-webdesigner $REPOCONFIG/$DEFAULT_ARCH {$_,/^}$/d' "$URPMI_REPO_FILE"
#  fi
#}
#
#remove_yast() {
#  # Ideally, we would run: zypper removerepo "google-webdesigner"
#  # but that does not work when zypper is running.
#  rm -f /etc/zypp/repos.d/google-webdesigner.repo
#}

DEFAULT_ARCH="i386"

get_lib_dir() {
  if [ "$DEFAULT_ARCH" = "i386" ]; then
    LIBDIR=lib
  elif [ "$DEFAULT_ARCH" = "x86_64" ]; then
    LIBDIR=lib64
  else
    echo Unknown CPU Architecture: "$DEFAULT_ARCH"
    exit 1
  fi
}

# Symlink add/remove scripts for package installation/removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/symlinks.include
# All modifications for GWD are marked with a comment.
#

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary since GWD
#   has no dependence on the NSS libraries.
#
#  NSS_FILES="libnspr4.so.0d libplds4.so.0d libplc4.so.0d libssl3.so.1d \
#     libnss3.so.1d libsmime3.so.1d libnssutil3.so.1d"

# add_nss_symlinks() {
#   get_lib_dir
#   for f in $NSS_FILES
#   do
#     target=$(echo $f | sed 's/\.[01]d$//')
#     if [ -f "/$LIBDIR/$target" ]; then
#       ln -snf "/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     elif [ -f "/usr/$LIBDIR/$target" ]; then
#       ln -snf "/usr/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     else
#       echo $f not found in "/$LIBDIR/$target" or "/usr/$LIBDIR/$target".
#       exit 1
#     fi
#   done
# }

# remove_nss_symlinks() {
#   for f in $NSS_FILES
#   do
#     rm -rf "/opt/google/webdesigner/$f"
#   done
# }

# Fedora 18 now has libudev.so.1. http://crbug.com/145160
# Same for Ubuntu 13.04. http://crbug.com/226002
LIBUDEV_0=libudev.so.0
LIBUDEV_1=libudev.so.1

add_udev_symlinks() {
  get_lib_dir
  if [ -f "/$LIBDIR/$LIBUDEV_0" -o -f "/usr/$LIBDIR/$LIBUDEV_0" -o -f "/lib/$LIBUDEV_0" ]; then
    return 0
  fi

  if [ -f "/$LIBDIR/$LIBUDEV_1" ]; then
    ln -snf "/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  elif [ -f "/usr/$LIBDIR/$LIBUDEV_1" ];
  then
    ln -snf "/usr/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  else
    echo "$LIBUDEV_1" not found in "$LIBDIR" or "/usr/$LIBDIR".
    exit 1
  fi
}

remove_udev_symlinks() {
  rm -rf "/opt/google/webdesigner/$LIBUDEV_0"
}

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary.
#remove_nss_symlinks
#add_nss_symlinks

remove_udev_symlinks
add_udev_symlinks

DEFAULTS_FILE="/etc/default/google-webdesigner"
if [ ! -e "$DEFAULTS_FILE" ]; then
  echo 'repo_add_once="true"' > "$DEFAULTS_FILE"
fi

. "$DEFAULTS_FILE"

if [ "$repo_add_once" = "true" ]; then
  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    install_yum
    ;;
  "urpmi")
    install_urpmi
    ;;
  "yast")
    install_yast
    ;;
  esac
fi

# Some package managers have locks that prevent everything from being
# configured at install time, so wait a bit then kick the cron job to do
# whatever is left. Probably the db will be unlocked by then, but if not, the
# cron job will keep retrying.
# Do this with 'at' instead of a backgrounded shell because zypper waits on all
# sub-shells to finish before it finishes, which is exactly the opposite of
# what we want here. Also preemptively start atd because for some reason it's
# not always running, which kind of defeats the purpose of having 'at' as a
# required LSB command.
service atd start
echo "sh /etc/cron.daily/google-webdesigner" | at now + 2 minute > /dev/null 2>&1

CHANNEL=stable
# GWD Modification
#   Remove case statement on CHANNEL and set priority to 200 which is the value
#   for Chrome stable.
PRIORITY=200

# GWD Modification
#   Remvoed the update-alternatives call as GWD is not an alternative app that
#   the OS needs to be aware of.
# /usr/sbin/update-alternatives --install /usr/bin/google-webdesigner google-webdesigner \
#   /usr/bin/google-webdesigner $PRIORITY

exit 0

#------------------------------------------------------------------------------
#   Pre uninstallation script
#------------------------------------------------------------------------------
preuninstall scriptlet (using /bin/sh):

# This is copied from:
#   /trunk/src/chrome/installer/linux/rpm/chrome.spec-template
# All modifications for GWD are marked with a comment.

if [ "$1" -eq "0" ]; then
  mode="uninstall"
elif [ "$1" -eq "1" ]; then
  mode="upgrade"
fi

# RPM repository management scripts for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/rpm.include
# All modifications for GWD are marked with a comment.
#
# GWD Modification
#   Updated include path as variables.include is located in the common folder
#    for GWD.
# Shared variable script for package installation.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/variables.include
# All modifications for GWD are marked with a comment.
#
# System-wide package configuration.
DEFAULTS_FILE="/etc/default/google-webdesigner"

# sources.list setting for google-webdesigner updates.
REPOCONFIG="http://dl.google.com/linux/webdesigner/rpm/stable"

# Install the repository signing key (see also:
# http://www.google.com/linuxrepositories/aboutkey.html)
install_rpm_key() {
  # Check to see if key already exists.
  rpm -q gpg-pubkey-7fac5991-4615767f > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi
  # This is to work around a bug in RPM 4.7.0. (see http://crbug.com/22312)
  rpm -q gpg-pubkey-7fac5991-45f06f46 > /dev/null 2>&1
  if [ "$?" -eq "0" ]; then
    # Key already exists
    return 0
  fi

  # RPM on Mandriva 2009 is dumb and does not understand "rpm --import -"
  TMPKEY=$(mktemp /tmp/google.sig.XXXXXX)
  if [ -n "$TMPKEY" ]; then
    cat > "$TMPKEY" <<KEYDATA
-----BEGIN PGP PUBLIC KEY BLOCK-----
Version: GnuPG v1.4.2.2 (GNU/Linux)

mQGiBEXwb0YRBADQva2NLpYXxgjNkbuP0LnPoEXruGmvi3XMIxjEUFuGNCP4Rj/a
kv2E5VixBP1vcQFDRJ+p1puh8NU0XERlhpyZrVMzzS/RdWdyXf7E5S8oqNXsoD1z
fvmI+i9b2EhHAA19Kgw7ifV8vMa4tkwslEmcTiwiw8lyUl28Wh4Et8SxzwCggDcA
feGqtn3PP5YAdD0km4S4XeMEAJjlrqPoPv2Gf//tfznY2UyS9PUqFCPLHgFLe80u
QhI2U5jt6jUKN4fHauvR6z3seSAsh1YyzyZCKxJFEKXCCqnrFSoh4WSJsbFNc4PN
b0V0SqiTCkWADZyLT5wll8sWuQ5ylTf3z1ENoHf+G3um3/wk/+xmEHvj9HCTBEXP
78X0A/0Tqlhc2RBnEf+AqxWvM8sk8LzJI/XGjwBvKfXe+l3rnSR2kEAvGzj5Sg0X
4XmfTg4Jl8BNjWyvm2Wmjfet41LPmYJKsux3g0b8yzQxeOA4pQKKAU3Z4+rgzGmf
HdwCG5MNT2A5XxD/eDd+L4fRx0HbFkIQoAi1J3YWQSiTk15fw7RMR29vZ2xlLCBJ
bmMuIExpbnV4IFBhY2thZ2UgU2lnbmluZyBLZXkgPGxpbnV4LXBhY2thZ2VzLWtl
eW1hc3RlckBnb29nbGUuY29tPohjBBMRAgAjAhsDBgsJCAcDAgQVAggDBBYCAwEC
HgECF4AFAkYVdn8CGQEACgkQoECDD3+sWZHKSgCfdq3HtNYJLv+XZleb6HN4zOcF
AJEAniSFbuv8V5FSHxeRimHx25671az+uQINBEXwb0sQCACuA8HT2nr+FM5y/kzI
A51ZcC46KFtIDgjQJ31Q3OrkYP8LbxOpKMRIzvOZrsjOlFmDVqitiVc7qj3lYp6U
rgNVaFv6Qu4bo2/ctjNHDDBdv6nufmusJUWq/9TwieepM/cwnXd+HMxu1XBKRVk9
XyAZ9SvfcW4EtxVgysI+XlptKFa5JCqFM3qJllVohMmr7lMwO8+sxTWTXqxsptJo
pZeKz+UBEEqPyw7CUIVYGC9ENEtIMFvAvPqnhj1GS96REMpry+5s9WKuLEaclWpd
K3krttbDlY1NaeQUCRvBYZ8iAG9YSLHUHMTuI2oea07Rh4dtIAqPwAX8xn36JAYG
2vgLAAMFB/wKqaycjWAZwIe98Yt0qHsdkpmIbarD9fGiA6kfkK/UxjL/k7tmS4Vm
CljrrDZkPSQ/19mpdRcGXtb0NI9+nyM5trweTvtPw+HPkDiJlTaiCcx+izg79Fj9
KcofuNb3lPdXZb9tzf5oDnmm/B+4vkeTuEZJ//IFty8cmvCpzvY+DAz1Vo9rA+Zn
cpWY1n6z6oSS9AsyT/IFlWWBZZ17SpMHu+h4Bxy62+AbPHKGSujEGQhWq8ZRoJAT
G0KSObnmZ7FwFWu1e9XFoUCt0bSjiJWTIyaObMrWu/LvJ3e9I87HseSJStfw6fki
5og9qFEkMrIrBCp3QGuQWBq/rTdMuwNFiEkEGBECAAkFAkXwb0sCGwwACgkQoECD
D3+sWZF/WACfeNAu1/1hwZtUo1bR+MWiCjpvHtwAnA1R3IHqFLQ2X3xJ40XPuAyY
/FJG
=Quqp
-----END PGP PUBLIC KEY BLOCK-----
KEYDATA
    rpm --import "$TMPKEY"
    rc=$?
    rm -f "$TMPKEY"
    if [ "$rc" -eq "0" ]; then
      return 0
    fi
  fi
  return 1
}

determine_rpm_package_manager() {
  local RELEASE
  LSB_RELEASE="$(which lsb_release 2> /dev/null)"
  if [ -x "$LSB_RELEASE" ]; then
    RELEASE=$(lsb_release -i 2> /dev/null | sed 's/:\t/:/' | cut -d ':' -f 2-)
    case $RELEASE in
    "Fedora")
      PACKAGEMANAGER=yum
      ;;
    "MandrivaLinux")
      PACKAGEMANAGER=urpmi
      ;;
    "SUSE LINUX")
      PACKAGEMANAGER=yast
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  # Fallback methods that are probably unnecessary on modern systems.
  if [ -f "/etc/lsb-release" ]; then
    # file missing on Fedora, does not contain DISTRIB_ID on OpenSUSE.
    eval $(sed -e '/DISTRIB_ID/!d' /etc/lsb-release)
    case $DISTRIB_ID in
    MandrivaLinux)
      PACKAGEMANAGER=urpmi
      ;;
    esac
  fi

  if [ "$PACKAGEMANAGER" ]; then
    return
  fi

  if [ -f "/etc/fedora-release" ] || [ -f "/etc/redhat-release" ]; then
    PACKAGEMANAGER=yum
  elif [ -f "/etc/SuSE-release" ]; then
    PACKAGEMANAGER=yast
  elif [ -f "/etc/mandriva-release" ]; then
    PACKAGEMANAGER=urpmi
  fi
}

DEFAULT_ARCH="i386"
YUM_REPO_FILE="/etc/yum.repos.d/google-webdesigner.repo"
ZYPPER_REPO_FILE="/etc/zypp/repos.d/google-webdesigner.repo"
URPMI_REPO_FILE="/etc/urpmi/urpmi.cfg"

install_yum() {
  install_rpm_key

  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  if [ -d "/etc/yum.repos.d" ]; then
cat > "$YUM_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
baseurl=$REPOCONFIG/$DEFAULT_ARCH
enabled=1
gpgcheck=1
REPOCONTENT
  fi
}

# This is called by the cron job, rather than in the RPM postinstall.
# We cannot do this during the install when urpmi is running due to
# database locking. We also need to enable the repository, and we can
# only do that while we are online.
# see: https://qa.mandriva.com/show_bug.cgi?id=31893
configure_urpmi() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  urpmq --list-media | grep -q -s "^google-webdesigner$"
  if [ "$?" -eq "0" ]; then
    # Repository already configured
    return 0
  fi
  urpmi.addmedia --update \
    "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_urpmi() {
  # urpmi not smart enough to pull media_info/pubkey from the repository?
  install_rpm_key

  # Defer urpmi.addmedia to configure_urpmi() in the cron job.
  # See comment there.
  #
  # urpmi.addmedia --update \
  #   "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

install_yast() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  # We defer adding the key to later. See comment in the cron job.

  # Ideally, we would run: zypper addrepo -t YUM -f \
  # "$REPOCONFIG/$DEFAULT_ARCH" "google-webdesigner"
  # but that does not work when zypper is running.
  if [ -d "/etc/zypp/repos.d" ]; then
cat > "$ZYPPER_REPO_FILE" << REPOCONTENT
[google-webdesigner]
name=google-webdesigner
enabled=1
autorefresh=1
baseurl=$REPOCONFIG/$DEFAULT_ARCH
type=rpm-md
keeppackages=0
REPOCONTENT
  fi
}

# Check if the automatic repository configuration is done, so we know when to
# stop trying.
verify_install() {
  # It's probably enough to see that the repo configs have been created. If they
  # aren't configured properly, update_bad_repo should catch that when it's run.
  case $1 in
  "yum")
    [ -f "$YUM_REPO_FILE" ]
    ;;
  "yast")
    [ -f "$ZYPPER_REPO_FILE" ]
    ;;
  "urpmi")
    urpmq --list-url | grep -q -s "\bgoogle-webdesigner\b"
    ;;
  esac
}

# Update the Google repository if it's not set correctly.
update_bad_repo() {
  if [ ! "$REPOCONFIG" ]; then
    return 0
  fi

  determine_rpm_package_manager

  case $PACKAGEMANAGER in
  "yum")
    update_repo_file "$YUM_REPO_FILE"
    ;;
  "yast")
    update_repo_file "$ZYPPER_REPO_FILE"
    ;;
  "urpmi")
    update_urpmi_cfg
    ;;
  esac
}

update_repo_file() {
  REPO_FILE="$1"

  # Don't do anything if the file isn't there, since that probably means the
  # user disabled it.
  if [ ! -r "$REPO_FILE" ]; then
    return 0
  fi

  # Check if the correct repository configuration is in there.
  REPOMATCH=$(grep "^baseurl=$REPOCONFIG/$DEFAULT_ARCH" "$REPO_FILE" \
    2>/dev/null)
  # If it's there, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Check if it's there but disabled by commenting out (as opposed to using the
  # 'enabled' setting).
  MATCH_DISABLED=$(grep "^[[:space:]]*#.*baseurl=$REPOCONFIG/$DEFAULT_ARCH" \
    "$REPO_FILE" 2>/dev/null)
  if [ "$MATCH_DISABLED" ]; then
    # It's OK for it to be disabled, as long as nothing bogus is enabled in its
    # place.
    ACTIVECONFIGS=$(grep "^baseurl=.*" "$REPO_FILE" 2>/dev/null)
    if [ ! "$ACTIVECONFIGS" ]; then
      return 0
    fi
  fi

  # If we get here, the correct repository wasn't found, or something else is
  # active, so fix it. This assumes there is a 'baseurl' setting, but if not,
  # then that's just another way of disabling, so we won't try to add it.
  sed -i -e "s,^baseurl=.*,baseurl=$REPOCONFIG/$DEFAULT_ARCH," "$REPO_FILE"
}

update_urpmi_cfg() {
  REPOCFG=$(urpmq --list-url | grep "\bgoogle-webdesigner\b")
  if [ ! "$REPOCFG" ]; then
    # Don't do anything if the repo isn't there, since that probably means the
    # user deleted it.
    return 0
  fi

  # See if it's the right repo URL
  REPOMATCH=$(echo "$REPOCFG" | grep "\b$REPOCONFIG/$DEFAULT_ARCH\b")
  # If so, nothing to do
  if [ "$REPOMATCH" ]; then
    return 0
  fi

  # Looks like it's the wrong URL, so recreate it.
  urpmi.removemedia "google-webdesigner" && \
    urpmi.addmedia --update "google-webdesigner" "$REPOCONFIG/$DEFAULT_ARCH"
}

# We only remove the repository configuration during a purge. Since RPM has
# no equivalent to dpkg --purge, the code below is actually never used. We
# keep it only for reference purposes, should we ever need it.
#
#remove_yum() {
#  rm -f "$YUM_REPO_FILE"
#}
#
#remove_urpmi() {
#  # Ideally, we would run: urpmi.removemedia "google-webdesigner"
#  # but that does not work when urpmi is running.
#  # Sentinel comment text does not work either because urpmi.update removes
#  # all comments. So we just delete the entry that matches what we originally
#  # inserted. If such an entry was added manually, that's tough luck.
#  if [ -f "$URPMI_REPO_FILE" ]; then
#    sed -i '\_^google-webdesigner $REPOCONFIG/$DEFAULT_ARCH {$_,/^}$/d' "$URPMI_REPO_FILE"
#  fi
#}
#
#remove_yast() {
#  # Ideally, we would run: zypper removerepo "google-webdesigner"
#  # but that does not work when zypper is running.
#  rm -f /etc/zypp/repos.d/google-webdesigner.repo
#}

DEFAULT_ARCH="i386"

get_lib_dir() {
  if [ "$DEFAULT_ARCH" = "i386" ]; then
    LIBDIR=lib
  elif [ "$DEFAULT_ARCH" = "x86_64" ]; then
    LIBDIR=lib64
  else
    echo Unknown CPU Architecture: "$DEFAULT_ARCH"
    exit 1
  fi
}

# Symlink add/remove scripts for package installation/removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/symlinks.include
# All modifications for GWD are marked with a comment.
#

# GWD Modification
#   Commented out for Web Designer as this shouldn't be necessary since GWD
#   has no dependence on the NSS libraries.
#
#  NSS_FILES="libnspr4.so.0d libplds4.so.0d libplc4.so.0d libssl3.so.1d \
#     libnss3.so.1d libsmime3.so.1d libnssutil3.so.1d"

# add_nss_symlinks() {
#   get_lib_dir
#   for f in $NSS_FILES
#   do
#     target=$(echo $f | sed 's/\.[01]d$//')
#     if [ -f "/$LIBDIR/$target" ]; then
#       ln -snf "/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     elif [ -f "/usr/$LIBDIR/$target" ]; then
#       ln -snf "/usr/$LIBDIR/$target" "/opt/google/webdesigner/$f"
#     else
#       echo $f not found in "/$LIBDIR/$target" or "/usr/$LIBDIR/$target".
#       exit 1
#     fi
#   done
# }

# remove_nss_symlinks() {
#   for f in $NSS_FILES
#   do
#     rm -rf "/opt/google/webdesigner/$f"
#   done
# }

# Fedora 18 now has libudev.so.1. http://crbug.com/145160
# Same for Ubuntu 13.04. http://crbug.com/226002
LIBUDEV_0=libudev.so.0
LIBUDEV_1=libudev.so.1

add_udev_symlinks() {
  get_lib_dir
  if [ -f "/$LIBDIR/$LIBUDEV_0" -o -f "/usr/$LIBDIR/$LIBUDEV_0" -o -f "/lib/$LIBUDEV_0" ]; then
    return 0
  fi

  if [ -f "/$LIBDIR/$LIBUDEV_1" ]; then
    ln -snf "/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  elif [ -f "/usr/$LIBDIR/$LIBUDEV_1" ];
  then
    ln -snf "/usr/$LIBDIR/$LIBUDEV_1" "/opt/google/webdesigner/$LIBUDEV_0"
  else
    echo "$LIBUDEV_1" not found in "$LIBDIR" or "/usr/$LIBDIR".
    exit 1
  fi
}

remove_udev_symlinks() {
  rm -rf "/opt/google/webdesigner/$LIBUDEV_0"
}

# Only remove menu items and symlinks on uninstall. When upgrading,
# old_pkg's %preun runs after new_pkg's %post.
if [ "$mode" = "uninstall" ]; then
# Pre remove scripts for package removal.
# This is a direct copy of:
#   /trunk/src/chrome/installer/linux/common/prerm.include
# All modifications for GWD are marked with a comment.
#

# Remove icons from the system icons
XDG_ICON_RESOURCE="`which xdg-icon-resource 2> /dev/null || true`"
if [ ! -x "$XDG_ICON_RESOURCE" ]; then
  echo "Error: Could not find xdg-icon-resource" >&2
  exit 1
fi
# GWD Modification
#   Added /resources/ below as the GWD icons are located in a subdirectory
#   next to the main executable.
for icon in "/opt/google/webdesigner/resources/product_logo_"*.png; do
  size="${icon##*/product_logo_}"
  "$XDG_ICON_RESOURCE" uninstall --size "${size%.png}" "google-webdesigner"
done

UPDATE_MENUS="`which update-menus 2> /dev/null || true`"
if [ -x "$UPDATE_MENUS" ]; then
  update-menus
fi

# GWD Modification
#   Remove our registered custom template protocol.
gconftool-2 --recursive-unset /desktop/gnome/url-handlers/gwd-template

# Update cache of .desktop file MIME types. Non-fatal since it's just a cache.
update-desktop-database || true

# GWD Modification
# Commented out for Web Designer as this shouldn't be necessary.
# remove_nss_symlinks
  remove_udev_symlinks

# GWD Modification
#   Remvoed the update-alternatives call as GWD is not an alternative app that
#   the OS needs to be aware of.
#   /usr/sbin/update-alternatives --remove google-webdesigner \
#     /usr/bin/google-webdesigner
fi

# On Debian we only remove when we purge. However, RPM has no equivalent to
# dpkg --purge, so this is all disabled.
#
#determine_rpm_package_manager
#
#case $PACKAGEMANAGER in
#"yum")
#  remove_yum
#  ;;
#"urpmi")
#  remove_urpmi
#  ;;
#"yast")
#  remove_yast
#  ;;
#esac

exit 0

#------------------------------------------------------------------------------
#   Post uninstallation script
#------------------------------------------------------------------------------
postuninstall scriptlet (using /bin/sh):

exit 0
[root@localhost Descargas]#


It appears more complete the log, i hope this could help you, and maybe the entire community. Thanks for respond.
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby doktor5000 » Apr 11th, '16, 18:34

I cannot really reproduce, after installation it can be started just fine.

Code: Select all
[doktor5000@Mageia5]─[18:26:46]─[~] sudo LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_x86_64.rpm


installing google-webdesigner_current_x86_64.rpm from /var/cache/urpmi/partial
Preparing...                     ################################################################################################################################################################################
      1/1: google-webdesigner    ################################################################################################################################################################################

(gconftool-2:22504): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: No D-BUS daemon running


(gconftool-2:22505): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: No D-BUS daemon running


(gconftool-2:22506): GConf-WARNING **: Client failed to connect to the D-BUS daemon:
Did not receive a reply. Possible causes include: the remote application did not send a reply, the message bus security policy blocked the reply, the reply timeout expired, or the network connection was broken.
Error setting value: No D-BUS daemon running

Warning in file "/usr/share/applications/epiphany.desktop": usage of MIME type "multipart/related" is discouraged ("multipart" is a media type that probably does not make sense in this context)
Warning in file "/usr/share/applications/epiphany.desktop": usage of MIME type "multipart/related" is discouraged ("multipart" is a media type that probably does not make sense in this context)
Redirecting to /bin/systemctl start atd.service
[doktor5000@Mageia5]─[18:27:06]─[~]


Starting it works fine (LC_ALL=C is only there to produce english output)

Code: Select all
[doktor5000@Mageia5]─[18:28:18]─[~] LC_ALL=C google-webdesigner                                                                                                                                           
which: no opera in (/bin:/usr/bin:/usr/local/bin:/usr/local/games:/usr/games:/usr/lib64/qt4/bin:/usr/lib64/qt5/bin:/home/doktor5000/bin)                                                                           
[0411/182837:ERROR:nss_util.cc(845)] After loading Root Certs, loaded==false: NSS error code: -8018


By the way, you tried to start it as root, which is a really bad idea - you should never start any graphical applications as root.

Bildschirmfoto2_246.png
Bildschirmfoto2_246.png (48.23 KiB) Viewed 6128 times


Please show the output as root of
Code: Select all
rpm -q google-webdesigner; rpm -V google-webdesigner


Can you please try the installation again as root via
Code: Select all
LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_x86_64.rpm
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18056
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 12th, '16, 14:00

First your petitions:

Please show the output as root of rpm -q google-webdesigner; rpm -V google-webdesigner


Code: Select all
[root@localhost miguel]# cd Descargas
[root@localhost Descargas]# rpm -q google-webdesigner; rpm -V google-webdesigner
google-webdesigner-1.2.5.0-1
[root@localhost Descargas]#


NOTE: "Descargas" is the name folder for the directory Downloads, they are the same and is the equal name in translation to the english mageia 5 from spanish mageia 5. And consider that I'm posting this after installing it again using your recomendation, consider too that may be different number versions between 32bit & 64bit architecture builds.

Now @doktor5000, you create on me new question based on what you show me when you installed the app, I never installed nothing before as a mere user, only as a root, besides, I never run my apps in root mode always, only for testing them the first time, by the way, no apps before and now give to me problems, I know that it is not recommended but for test it the first time can't be so harm, and some apps can benefit from it, specially those without repositories like Firefox Nightly and LibreOffice, I tried to do the same think as you do for installation, assuming that you have installed epiphany & google chrome in your 64bit user pc (but remember, i am a 32bit user), and this was the result:

Code: Select all
[miguel@localhost ~]$ sudo LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_i386.rpm
[sudo] password for miguel:
miguel is not in the sudoers file.  This incident will be reported.
[miguel@localhost ~]$


That message came the second time that I tried, the first time additionally expose 3 rules if I recall (1 don't bother other users, 2 a great power came with great responsibility, 3 this will be reported in a log file.).

I don't even understand to who will be reported this action... Now, a different history is as a root (NOTE: I never installed google web designer as you did, i'm making the same as you to reproduce the data), this is the result:

Code: Select all
[root@localhost Descargas]# sudo LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_i386.rpm


installing google-webdesigner_current_i386.rpm from /var/cache/urpmi/partial
Preparing...                     #####################################################################################################################################
      1/1: google-webdesigner    #####################################################################################################################################
touch: cannot touch '/root/.local/share/applications/mimeapps.list': No such file or directory
/bin/xdg-mime: line 832: /root/.local/share/applications/mimeapps.list.new: No such file or directory
Redirecting to /bin/systemctl start atd.service
[root@localhost Descargas]#


:oops: I forgot to explain a detail, some users think that the problem came with linux installations of others languages except english:

what worked for me eventually, was to set my language/locale to english, remove the webdesigner directory, and launch it once like that. after succesful run, I set my language back to finnish that I had before.

so you could try:
1) rm -R -f ~/.local/share/google-web-designer
2) LANGUAGE=en google-webdesigner

if it doesn't work you can also set LANG to "en_US.UTF-8" for example..
but I think LANGUAGE is the key here..

if you are already on english language system, then sadly, I don't know what's wrong..

.b


I never try that, I don't even know how to do that, I don't even understand if this user is just erasing the foler directory or file mentioned before as first in this post.

Now, after installing it as a root, i pass to execute it as a mere user:

Code: Select all
[root@localhost Descargas]# exit
exit
[miguel@localhost ~]$ google-webdesigner
which: no google-chrome in (/usr/local/bin:/usr/bin:/usr/local/games:/usr/games:/usr/lib/qt4/bin:/usr/lib/qt5/bin:/home/miguel/bin)


The result:

http://www.subirimagenes.com/imagedata. ... talla2.png

And the Blank screen persist... there are users who believe the problem is the language... How can i force an app in terminal as mere user or root or manually in a launcher to change the language of an app to only english for test?. And I mean force to not have to change my entire language installation into english o worse, reinstall the entire distro in english.
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby doktor5000 » Apr 13th, '16, 17:12

mianrosu wrote:
Code: Select all
[root@localhost miguel]# cd Descargas
[root@localhost Descargas]# rpm -q google-webdesigner; rpm -V google-webdesigner
google-webdesigner-1.2.5.0-1
[root@localhost Descargas]#

This means that the package google-webdesigner is installed OK, and all checksums for all files contained in the package were verified OK against the actually installed files, so google-webdesigner package installed all files just fine.


mianrosu wrote:
Code: Select all
[miguel@localhost ~]$ sudo LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_i386.rpm
[sudo] password for miguel:
miguel is not in the sudoers file.  This incident will be reported.
[miguel@localhost ~]$


That message came the second time that I tried, the first time additionally expose 3 rules if I recall (1 don't bother other users, 2 a great power came with great responsibility, 3 this will be reported in a log file.).

I don't even understand to who will be reported this action... Now, a different history is as a root (NOTE: I never installed google web designer as you did, i'm making the same as you to reproduce the data), this is the result:

Code: Select all
[root@localhost Descargas]# sudo LC_ALL=C urpmi https://dl.google.com/linux/direct/google-webdesigner_current_i386.rpm



This has not been actually reported to anybody, this is the standard return you receive when you run sudo when it is not configured. See e.g. https://wiki.mageia.org/en/Configuring_sudo
You don't need sudo, that's why I omitted it in the command that you should run, it's basically just a bad habit of mine.

The second output you posted is OK, as when you run sudo as root it will basically just ignore it as you are already root. The installation was OK.

mianrosu wrote:
Code: Select all
[root@localhost Descargas]# exit
exit
[miguel@localhost ~]$ google-webdesigner
which: no google-chrome in (/usr/local/bin:/usr/bin:/usr/local/games:/usr/games:/usr/lib/qt4/bin:/usr/lib/qt5/bin:/home/miguel/bin)



Seems I misread the initial error message. google-webdesigner seems to require an installed copy of google-chrome (which I've installed as I'm using chrome, hence it launches just fine on my box) so you would need to install chrome. This is actually an issue with the package of google-webdesigner and should probably be reported to google support so they can improve this, and either bundle the latest copy of chrome or the runtime they require, or tell users that they need to install chrome.

For the chrome installation, it's pretty easy and explained in our MAQeia for chrome: viewtopic.php?f=36&t=2053
Please install chrome, then try to run google-webdesigner again.

mianrosu wrote:And the Blank screen persist... there are users who believe the problem is the language... How can i force an app in terminal as mere user or root or manually in a launcher to change the language of an app to only english for test?. And I mean force to not have to change my entire language installation into english o worse, reinstall the entire distro in english.


That's what I mentioned with prefixing any command by LC_ALL=C this sets all locale settings (language, measurements, time format) to C locale which is english, but does this only for the command following it. It does not changing anything about the language of the installed system, but is a perfect way to "force an app in terminal as mere user or root or manually in a launcher to change the language of an app to only english for test" as you said it :)

A few applications do not respect the LC_ALL variable, in that case you could try using LANGUAGE=en instead, as in the example you mentioned.
The other command
Code: Select all
rm -R -f ~/.local/share/google-web-designer
would simply delete all your google-webdesigner user settings, which is a bad idea.


If you have any further questions, don't hesitate to ask.
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18056
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 14th, '16, 08:04

Seems I misread the initial error message. google-webdesigner seems to require an installed copy of google-chrome (which I've installed as I'm using chrome, hence it launches just fine on my box) so you would need to install chrome.


It is not possible to install google chrome into a linux 32bit architecture anymore... And I don't see nobody sharing a package of 32bit of google chrome to install for test nor i have seen an ESR type like firefox (if I'm not mistaken). I hope not to sound rude, but it's frustrating and i apologize for that.

Google Kill Google Chrome for 32bit users on all Linux

This is a big problem for me, when a standard pc with an OS windows like 8 / 10 in my country have a cost nearly 16 times the standard wage... And buying the food and other things to use in the week have a cost of 52% of the minimum wage, yes, in my country nobody with minimum wage as a salary can live alone. Maybe this is an exaggeration to discuss this or think into this just by a mere app, but is still frustrating and I'm feeling behind by the technologies.

Worst is, if it is truth your affirmation of google-webdesigner need to have installed google chrome, it will never run on 32bit architectures either...

Thanks for your support, i'll going to register into google support to report this issue, if it is an issue and not a mistake (like it was planned to retire google web-designer for 32bit architecture with google chrome for 32bit users as well).
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby doktor5000 » Apr 14th, '16, 19:07

mianrosu wrote:Thanks for your support, i'll going to register into google support to report this issue, if it is an issue and not a mistake (like it was planned to retire google web-designer for 32bit architecture with google chrome for 32bit users as well).


Well, from the error message it obviously seems to require chrome, as for me it runs just fine with chrome installed, and for you it only seems to show an empty/black window.
Best provide a link if you have created your support request, in case further troubleshooting or more detailed information about Mageia is required, I'd be more then happy to help.

Apart from that, what CPU do you have that you can't install x86_64 ?
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18056
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 15th, '16, 07:19

doktor5000 wrote:Best provide a link if you have created your support request, in case further troubleshooting or more detailed information about Mageia is required, I'd be more then happy to help.

Apart from that, what CPU do you have that you can't install x86_64 ?


As promised this is the thread https://groups.google.com/forum/#!topic ... gm5sPm7Z5Y

And about my CPU, well... it must be an 64bit architecture but i never thought to install an 64bit OS because i heard that everything consumes more RAM than with just a 32bit architecture and my laptop is limited to 3GB of RAM, i don't have enough courage to prove if it will be a correct decision to change, besides, the original OS of my Acer Aspire 4935 was windows vista home edition basic iirc.

According to the instructions and explanations of this site http://www.cyberciti.biz/faq/linux-how- ... it-or-not/ with this way it can be revealed the architecture of the system:

Code: Select all
[miguel@localhost ~]$ grep flags /proc/cpuinfo
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm dtherm
flags      : fpu vme de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pat pse36 clflush dts acpi mmx fxsr sse sse2 ss ht tm pbe nx lm constant_tsc arch_perfmon pebs bts aperfmperf pni dtes64 monitor ds_cpl est tm2 ssse3 cx16 xtpr pdcm sse4_1 xsave lahf_lm dtherm
[miguel@localhost ~]$ grep -o -w 'lm' /proc/cpuinfo | sort -u
lm
[miguel@localhost ~]$


Mageia Control Center in Hardware, identifies my processor as a ‎Intel(R) Core(TM)2 Duo CPU T6400 @ 2.00GHz.
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby doktor5000 » Apr 15th, '16, 22:38

mianrosu wrote:As promised this is the thread https://groups.google.com/forum/#!topic ... gm5sPm7Z5Y

The description there is much too far from the actual issue. Best just add the normal output when you try to start webdesigner:

Code: Select all
[miguel@localhost ~]$ google-webdesigner
which: no google-chrome in (/usr/local/bin:/usr/bin:/usr/local/games:/usr/games:/usr/lib/qt4/bin:/usr/lib/qt5/bin:/home/miguel/bin)
Cauldron is not for the faint of heart!
Caution: Hot, bubbling magic inside. May explode or cook your kittens!
----
Disclaimer: Beware of allergic reactions in answer to unconstructive complaint-type posts
User avatar
doktor5000
 
Posts: 18056
Joined: Jun 4th, '11, 10:10
Location: Leipzig, Germany

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » Apr 15th, '16, 23:19

Thanks, i forgot complete it thinking in the possibility of Google kill GWD for 32bit users as well and with other thoughts around some problems in my work place too =/. It is updated now.
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28

Re: Solution to blank screen with google webdesigner on Mage

Postby mianrosu » May 4th, '16, 01:42

About the problem on GWD for 32bits users...

Hello Google Web Designer Community,

As some of you may be aware Chrome recently announced that they will drop support for 32-bit Linux as well as Ubuntu Precise (12.04), and Debian 7 (wheezy) in early March.

Google Web Designer will also end support for 32-bit Linux as well as Ubuntu Precise (12.04), and Debian 7 (wheezy) in early May. Users on these operating systems will still be able to run their existing version of Google Web Designer but will no longer receive updates or bug fixes. We are committed to the Linux platform and will continue to support Ubuntu 14.04+, Debian 8+, openSUSE 13.1+, and Fedora Linux 22+.

Cheers,

Sean Kranzberg
Engineering Manager
Google Web Designer


https://groups.google.com/forum/#!topic ... _vkD5za-9w
mianrosu
 
Posts: 9
Joined: Apr 9th, '16, 04:28


Return to Basic support

Who is online

Users browsing this forum: No registered users and 1 guest