[HOWTO] for a desktop not a laptop, getting a localization with firefox

Your PC does not move. It stays at home.

Geoclue is installed and activated by default with tumbleweed.

Default settings in /etc/geoclue/geoclue.conf is good. No need to alter the default settings.

You don’t have any way to get your localization. it’s important. If yes, then this way is used, even my solution is activated. You can disable all the other ways by settings “enable=false” for each other way in /ect/geoclue/geoclue.conf file.

Create in /etc a file named “geolocation”

get the coordinates and elevation of your home with https://whatismyelevation.com/

put in “geolocation” file the following statements (it’s an example) :

# Latitude (in decimal)
41.33648
# Longitude (in decimal)
2.11697
# Elevation (in meters)
14
# Accuracy radius (in meters)
0

check with the following command all is running well

/usr/libexec/geoclue-2.0/demos/where-am-i

thats all

Enjoy

1 Like

Thanks, this is something I was already looking for but did not finish, creating /etc/geolocation works.

I did paste the example data into /etc/geolocation and started QGIS, Enabled the GPS Information panel and connected the GPS and that shows the information:

Screenshot_20241105_083818

Next I will make a script to update the file based on where I like to be.

Hey, I’m glad it worked!

I forgot to mention this solution works for all apps using Geoclue as Marble using Qt positioning.