Python Forum
Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
How to make Python MakeFile
#2
I'm going to go ahead and post this here since there is so little on the internet about making python makefiles. This is what I used (and it works):

PY=python3
ZIP=abacmonitor.zip
MAIN=main
DIR=$(PWD)
.SUFFIXES: .py
FILES = \
	abacmonitor.py
All: 
	echo " $(PY) $(DIR)/$(FILES) " \"'$$1'\" > abacmonitor
	chmod 777 abacmonitor
A little explaination:

PY=python3 (this is my python version)

FILES (this is my python file. I only had one)

All: (this is the main part of it which grabs the python version, directory location, and filename and uses it alongside another command $$1 which works with another file to feed input from .txt files as arguments into the program.)
Reply


Messages In This Thread
How to make Python MakeFile - by artblinked - Feb-20-2019, 03:40 AM
RE: How to make Python MakeFile - by artblinked - Feb-22-2019, 03:09 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  make: *** [Makefile:29: all] Segmentation fault Anldra12 2 1,889 May-01-2022, 06:17 PM
Last Post: Anldra12
  Python project "pong" without any makefile sylas 5 5,018 Nov-28-2017, 05:55 PM
Last Post: Larz60+

Forum Jump:

User Panel Messages

Announcements
Announcement #1 8/1/2020
Announcement #2 8/2/2020
Announcement #3 8/6/2020