Currently experimenting with the Snappy packaging using a simple C++ program which converts GBP to USD. I have gone through documentation, but am still quite confused on how it works (having better luck with it compared to trying to figure out how to make a .deb package, though).
The 'snapcraft.yaml' file downloads the repo and runs the makefile to install the script in /usr/bin/.
snapcraft.yaml:
Code:
name: pound-to-us-dollarversion: 1
vendor: My Name <me@email.com@.com>
summary: Pound to US Dollar
description: converts money.
icon: icon.png
parts:
make-project:
plugin: make
source: git://github.com/<myUseame>/<myProject>.git
source-type: git
makefile: Makefile
Code:
CC=g++
CFLAGS=-c -Wall
install: pound-to-us-dollar
pound-to-us-dollar: main.o
$(CC) main.o -o /usr/bin/pound-to-us-dollar
main.o: main.cpp
$(CC) $(CFLAGS) main.cpp
clean:
rm -rf *o /usr/bin/pound-to-us-dollar
Code:
$ sudo snapcraft stage --force
When I finish off with:
Code:
$ sudo snapcraft
Can anyone who has the knowledge in this area tell if I have done this correctly or if there is a better way? I have created this from a full day of guess work.
- - , .
برچسب:
نویسنده: استخدام کار