Added qmake project files to repository; updated README and changed name so it would show up on GitHub; fixed permissions on enumcom.c

This commit is contained in:
Brett Weir 2015-02-19 21:57:00 -08:00
parent 229152ff8f
commit 6cd6fab90f
9 changed files with 126 additions and 17 deletions

42
README.md Normal file
View File

@ -0,0 +1,42 @@
# p1load
p1load is a tiny, nimble cross-platform loader library for the Propeller microcontroller.
## Building
`p1load` can be built in multiple ways.
### GNU Make
Building using plain old `make` is straight-forward. To build for the various platforms,
specify the target operating system using the `OS` variable.
```
OS=macosx make
```
Possible options:
* Mac OS X: `OS=macosx`
* Linux: `OS=linux`
* Raspberry Pi: `OS=raspberrypi`
* Windows MinGW: `OS=msys`
If no platform is specified, the default `macosx` is used.
### qmake
`qmake` project files can be found in the `qmake/` directory.
```
cd qmake
qmake
make
```
`qmake` will automatically build in platform-specific features except
for Raspberry Pi. Pass `CPU=armhf` to `qmake` to enable GPIO support for Raspberry Pi.
```
qmake CPU=armhf
```

0
enumcom.c Executable file → Normal file
View File

4
qmake/.gitignore vendored Normal file
View File

@ -0,0 +1,4 @@
Makefile
eeprom/eeprom
p1load/p1load
ploader/ploader

9
qmake/eeprom/eeprom.pro Normal file
View File

@ -0,0 +1,9 @@
include(../p1load.pri)
TEMPLATE = app
TARGET = eeprom
LIBS += -L$${OUT_PWD}/../ploader/ -lploader
SOURCES += \
../../eeprom.c \

16
qmake/p1load.pri Normal file
View File

@ -0,0 +1,16 @@
!greaterThan(QT_MAJOR_VERSION, 4): {
error("PropellerIDE requires Qt5.2 or greater")
}
!greaterThan(QT_MINOR_VERSION, 1): {
error("PropellerIDE requires Qt5.2 or greater")
}
CONFIG -= qt debug_and_release app_bundle
CONFIG += console
INCLUDEPATH += ../..
isEmpty(VERSION_ARG):VERSION_ARG = 0.0.0
VERSION_ARG = '\\"$${VERSION_ARG}\\"'
DEFINES += VERSION=\"$${VERSION_ARG}\"

9
qmake/p1load.pro Normal file
View File

@ -0,0 +1,9 @@
TEMPLATE = subdirs
SUBDIRS = \
ploader \
eeprom \
p1load \
eeprom.depends = ploader
p1load.depends = ploader

9
qmake/p1load/p1load.pro Normal file
View File

@ -0,0 +1,9 @@
include(../p1load.pri)
TEMPLATE = app
TARGET = p1load
LIBS += -L$${OUT_PWD}/../ploader/ -lploader
SOURCES += \
../../p1load.c \

37
qmake/ploader/ploader.pro Normal file
View File

@ -0,0 +1,37 @@
include(../p1load.pri)
TEMPLATE = lib
TARGET = ploader
CONFIG += staticlib
SOURCES += \
../../ploader.c \
../../packet.c \
../../port.c \
HEADERS += \
../../ploader.h
unix:!macx {
DEFINES += LINUX
SOURCES += \
../../osint_linux.c
equals(CPU, armhf) {
DEFINES += RASPBERRY_PI
SOURCES += \
../../gpio_sysfs.c
}
}
macx {
DEFINES += MACOSX
SOURCES += \
../../osint_linux.c
}
win32 {
DEFINES += MINGW
LIBS += -lsetupapi
SOURCES += \
../../osint_mingw.c \
../../enumcom.c
}

View File

@ -1,17 +0,0 @@
To build for the various platforms:
For Macintosh OS X:
OS=macosx make
For Linux:
OS=linux make
For the RaspberryPi:
OS=raspberrypi make
For Windows under MinGW:
OS=msys make