Google play services on xperia 10 III Sailfish 4.4.0.64

like said, Tile, https://www.apkmirror.com/apk/tile-inc/tile/tile-2-109-0-release/

Forget about any Android apps that need Bluetooth. Play Services is the least of your problems there.

what about programs like MobilePay


that don’t need bluetooth. is it possible to make it work. i installed FakeStore 0.1.0 but no difference. does not work.

Installing FakeStore did trick for me. Maybe check microg settings that everything checked there and of reboot Android compability or rebooting.

1 Like

Forget about all that low-level access stuff in the Android runtime.
Bluetooth, NFC, USB, VPN config, WiFi config etc.

This has been asked so many times.

You decide if the app qualifies - it appears to be some regional thing.
QR scanning (for apps that don’t build it in) might need the real deal to work, microG has had some issues.

Thanks, should i have checked also those which are not checked?

All that I have unchecked is:

Permission to access location in background
Permission to recive text messages
Permission to this app can appear on top of other apps.

Also do have Signature Spoofing Checker app showing Enabled?

arm arch | android 11 | “nemo” user | pico

Serious error: /home/.aliendalvik_systeming_patch/tmp/rpms/lzip-1.20-4.fc30.armv7hl.rpm has wrong architecture: armv7hl
umount: /home/.aliendalvik_systemimg_patch/tmp/systemimg_mount: no mount point specified

This came on 4.4.0.72 / 10 III

This has been worked for me on my Xperia 10 III with SFOS 4.5

I replaced the achitecture stuff simply by aarch64, arm64 and some more.

Enjoy.
installgapps_aarch64.sh

set -e

WORKDIR=/home/.aliendalvik_systemimg_patch
TMPWORKDIR="$WORKDIR/tmp"
SQUASHFS_ROOT="$TMPWORKDIR/squashfs-root"
MOUNT_ROOT="$TMPWORKDIR/systemimg_mount"
SYSTEM_IMG=/opt/alien/system.img
ORIG_IMG_FILE=orig_img_path.txt

FEDORA22_REPO=https://archives.fedoraproject.org/pub/archive/fedora/linux/releases/30/Everything/aarch64/os/Packages

OPENGAPPS_ARCH=arm64
OPENGAPPS_API=11.0
OPENGAPPS_VARIANT=pico

GOOGLE_APPS_REMOVE='carriersetup-all extservicesgoogle-arm64 extsharedgoogle-all googlebackuptransport-all googlecontactssync-all googlefeedback-all googlepartnersetup-all setupwizarddefault-arm64 setupwizardtablet-arm64 vending-common'

log() {
	printf '%s\n' "$1" > /dev/stderr
}

install_fedora22_rpm() {
	pkgname="$1"
	pkgversion="$2"

	if ! rpm -q "$pkgname" > /dev/null; then
		pkgfile="$pkgname-$pkgversion.fc30.aarch64.rpm"
		firstletter="$(printf '%s' "$pkgfile" | cut -c 1)"
		mkdir "$TMPWORKDIR/rpms"
		curl "$FEDORA22_REPO/$firstletter/$pkgfile" > "$TMPWORKDIR/rpms/$pkgfile"
		pkcon -y install-local "$TMPWORKDIR/rpms/$pkgfile"
		rm "$TMPWORKDIR/rpms/$pkgfile"
		rmdir "$TMPWORKDIR/rpms"
	fi
}

install_deps() {
	if ! rpm -q squashfs-tools > /dev/null; then
		log "squashfs-tools package not found. Installing..."
		pkcon -y install squashfs-tools
	fi
	
	if ! rpm -q rsync > /dev/null; then
		log "rsync package not found. Installing..."
		pkcon -y install rsync
	fi

	if ! rpm -q lzip > /dev/null; then
		log "lzip package not found. Installing..."
		install_fedora22_rpm lzip 1.20-4
	fi
}

extract_image() {
	mkdir "$MOUNT_ROOT"
	mount -o loop,ro "$SYSTEM_IMG" "$MOUNT_ROOT"

	if [ -f "$MOUNT_ROOT/$ORIG_IMG_FILE" ]; then
		orig_image="$(cat "$MOUNT_ROOT/$ORIG_IMG_FILE")"
		log "$SYSTEM_IMG already patched, using original from $orig_image"
	else
		orig_image="$WORKDIR/system.img.orig.$(date +%Y%m%dT%H%M%S)"
		cp "$SYSTEM_IMG" "$orig_image"
		log "Copying original image $SYSTEM_IMG to $orig_image"
	fi
	umount "$MOUNT_ROOT"

	if [ ! -f "$orig_image" ]; then
		log "$orig_image not found"
		return 1
	fi

	mount -o loop,ro "$orig_image" "$MOUNT_ROOT"

	if [ -f "$MOUNT_ROOT/$ORIG_IMG_FILE" ]; then
		umount "$MOUNT_ROOT"
		rmdir "$MOUNT_ROOT"
		log "$orig_image already patched, please restore original image to $SYSTEM_IMG"
		return 1
	fi

	mkdir "$SQUASHFS_ROOT"
	# rsync needs to be run twice to copy all xattrs. Probably a bug in rsync.
	rsync -aSHAX "$MOUNT_ROOT/" "$SQUASHFS_ROOT/"
	rsync -aSHAX "$MOUNT_ROOT/" "$SQUASHFS_ROOT/"
	umount "$MOUNT_ROOT"
	rmdir "$MOUNT_ROOT"

	printf '%s' "$orig_image" > "$SQUASHFS_ROOT/$ORIG_IMG_FILE"
}

build_image() {
	cp "$SYSTEM_IMG" "$TMPWORKDIR/system.img.backup"
	mksquashfs "$SQUASHFS_ROOT" "$SYSTEM_IMG" -noappend -no-exports -no-duplicates -no-fragments
	rm "$TMPWORKDIR/system.img.backup"
	rm -r "$SQUASHFS_ROOT"
}

_find_opengapps() {
	downloads=/home/defaultuser/Downloads/
	name_pattern="open_gapps-$OPENGAPPS_ARCH-$OPENGAPPS_API-$OPENGAPPS_VARIANT-*.zip"
	if [ "$1" != quiet ]; then
		log "Searching for Open GApps zip at $downloads/$name_pattern"
	fi
	find "$downloads" -maxdepth 1 -name "$name_pattern" | sort | tail -n 1
}

get_opengapps_zip() {
	opengapps_zip="$(_find_opengapps)"
	if [ -z "$opengapps_zip" ]; then
		# Show the Open GApps download page to the user instead of automating
		# the download of the latest version.
		# The no-mirror policy
		log "Opening Open GApps download page"
		runuser -l defaultuser – /usr/bin/xdg-open "The Open GApps Project"
		log "Waiting for download to start"
		while [ -z "$opengapps_zip" ]; do
			sleep 1
			opengapps_zip="$(_find_opengapps quiet)"
		done
		log "Detected new download at $opengapps_zip"
		log "Waiting for download to finish"
		while [ -f "$opengapps_zip" ] && [ -f "$opengapps_zip.part" ]; do
			sleep 1
		done
		sleep 1
		if [ ! -f "$opengapps_zip" ]; then
			log "Download failed"
			return 1
		fi
	else
		log "Found Open GApps zip $opengapps_zip"
	fi
	printf '%s' "$opengapps_zip"
}

install_opengapps() {
	log "Unzip open gapps archive"
	unzip "$(get_opengapps_zip)" -d "$TMPWORKDIR/opengapps/"

	log "Remove some google apps"
	for p in $GOOGLE_APPS_REMOVE; do
		log "Removing $p"
		rm "$TMPWORKDIR/opengapps/Core/$p.tar.lz"
	done

	if [ -f "$TMPWORKDIR/opengapps/Core/extservicesgoogle-all.tar.lz" ]; then
		rm -r "$SQUASHFS_ROOT/system/priv-app/ExtServices"
	fi

	if [ -f "$TMPWORKDIR/opengapps/Core/extsharedgoogle-all.tar.lz" ]; then
		rm -r "$SQUASHFS_ROOT/system/app/ExtShared"
	fi

	mkdir "$TMPWORKDIR/opengapps_unarchived"
	for f in "$TMPWORKDIR"/opengapps/Core/*.tar.lz; do
		lzip -c -d "$f" | tar -x -C "$TMPWORKDIR/opengapps_unarchived"
	done

	rm -r "$TMPWORKDIR/opengapps/"
	
	ls -al "$TMPWORKDIR"/opengapps_unarchived
	ls -al "$SQUASHFS_ROOT/system/"
	ls -al "$SQUASHFS_ROOT/system/product"
	cp -r "$TMPWORKDIR"/opengapps_unarchived/*/*/* "$SQUASHFS_ROOT/system/"
	rm -r "$TMPWORKDIR/opengapps_unarchived/"
}

set_traps() {
	# shellcheck disable=SC2064
	trap "$*" EXIT HUP INT QUIT PIPE TERM
}

cleanup() {
	if [ ! -f "$SYSTEM_IMG" ] && [ -f "$TMPWORKDIR/system.img.backup" ]; then
		mv "$TMPWORKDIR/system.img.backup" "$SYSTEM_IMG" || :
	fi
	umount "$MOUNT_ROOT" || :
	rm -r "$TMPWORKDIR" || :
	set_traps -
	exit 1
}

set_traps cleanup
systemctl stop aliendalvik

mkdir -p "$WORKDIR"
mkdir -p "$TMPWORKDIR"

install_deps
log "extract image"
extract_image
log "image was extracted"
log "install open gapps"
install_opengapps
log "open gapps were installed"
log "build image"
build_image
log "image was built"

rmdir "$TMPWORKDIR"

set_traps -
exit 0
4 Likes

Most values could be extracted from phones system so I think it is not so hard to rewrite the script it will used on both archs.

Thanks for all the good work here. Is anyone maintaining a proper GitHub repo for these scripts, do we know?

After installed sailfish 4.5 google play services stopped to work/ update. How I can make it update again. Sorry my poor english. I use the install gapps script.

That’s what I get:

extract image
Copying original image /opt/alien/system.img to /home/.aliendalvik_systemimg_patch/system.img.orig.20230329T130144
image was extracted
install open gapps
Unzip open gapps archive
Searching for Open GApps zip at /home/defaultuser/Downloads//open_gapps-arm64-11.0-pico-*.zip
Opening Open GApps download page
-bash: –: Tiedostoa tai hakemistoa ei ole
unzip: cannot find or open , .zip or .ZIP.
umount: /home/.aliendalvik_systemimg_patch/tmp/systemimg_mount: no mount point specified.

Edit: nevermind, it can be found here: OpenGApps - Browse /arm64/20220503 at SourceForge.net

CosmicStars’ script works, and no problems with google play, though its not available in Android emulation (some apps need it)

Yes it works, but google play services are not updated. Some apps like IL Paras sÀÀ( finnish weather app) doesn’t show a rain map, but there is a notification that google play services are being updated. I’m running sailfish 4.5.0.19

Can anybody helps me out with this? I’ve the 32bit Xperia 10 and sailfish 4.4
 How to rhn the script ? Adapt the script ? Thx otherwise well
 Bye google
EDIT: The script for the Xperia XA2 worked brilliant on my Xperia 10 I. I modified /home/nemo to /home/defaultuser. That’s all.
here it is opengappsinstallerforxperia10markI.sh - Google Drive

Does the gps data work for both goigle maps and whatsap, viber. When I use the script gps is not triggered from viber, whatsap or glympse but works great with some i
other apps like organic maps or here wego

You could try if starting a SFOS App which uses GPS like GPSInfo before starting an Android App which does not trigger the gps helps.

I have tested, while google maps has gps data, the other apps does not get it. As if sinething is broken for a group of apps but gps is working perfectly for others.