Opened 11 years ago

Closed 11 years ago

Last modified 11 years ago

#356 closed defect (fixed)

Bat file location independence

Reported by: anguscarr Owned by: jef
Priority: minor Component: Package
Version: Keywords:
Cc:

Description

The BAT files in OSGEO4w\bin are not all location independant. I want to set the program up to be location independant, so that I can make a portable version.

List of files I need to change to make this work: qgis-dev.bat qgis.bat qgis-browser.bat grass64.bat qgis-dev-browser.bat

They all initially start with set OSGEO4W_ROOT=<<My install location>> call %OSGEO4W_ROOT%\o4w_env.bat

I changed them to start with call %~dp0\o4w_env.bat

The bat files are now portable (afaik).

Can we change the template files to reflect this change?

Then I can package up an installer for distribution based on my local install. I'm sure there are issues with that, like the MSVC runtime installer, but I will work towards fixing those in the installer.

Change History (4)

comment:1 by maphew, 11 years ago

Owner: changed from osgeo4w-dev@… to jef

This is the recommended approach (http://trac.osgeo.org/osgeo4w/wiki/PackagingInstructions#Applicationbatchfiletemplate), though the qgis and grass .bat files probably predate that.

I don't see a downside to this, but Jurgen is package maintainer and in a better position to judge.

comment:2 by jef, 11 years ago

Resolution: fixed
Status: newclosed

fixed in qgis 1.8.0-6

in reply to:  2 ; comment:3 by anguscarr, 11 years ago

Replying to jef:

fixed in qgis 1.8.0-6

Did you also do qgis-dev?

in reply to:  3 comment:4 by jef, 11 years ago

Replying to anguscarr:

Did you also do qgis-dev?

yes. the next nightly build should have it.

Note: See TracTickets for help on using tickets.