[GIS] Making ‘make’-command work for compiling QGIS-plugins

osgeo4wpyqgisqgis-plugins

How can I compile my plugin when the 'make'-command refuses to work in the OSGeo4W Shell?

Can I make the 'make'-command work?

Is there an alternative out there?

I'm trying to build a plugin for QGIS. It's plugin Plugin Builder creates a projectfolder. According to tutorials I have to open the OSGeo4W Shell and compile the resources of my plugin by navigating to the project folder and execute the make-command. However, this doesn't work for me, saying:

'make' is not recognized as an internal or external command,operable
program or batch file.

I have a Windows sytem so that's not strange. Yet the OSGeo4W Shell should give me the abbility to use this command….I guesss. So I re-installed QGIS by using the Desktop Install by OSGeo4w in hope that it would configure the libraries correctly. Sadly with no effect.

Am I missing something?

Best Answer

You only really need to compile the resources of your plugin, in which case you can use:

pyrcc4 -o resources.py resources.qrc

No need to use make. If you want to properly clean up your resources, you could use make clean as described in this post: When I change a QGIS plugin's icon, why doesn't it change in the menu/toolbar?


Also, from the tutorial link you gave, a recent question was asked in the comments section :)

Related Question