forked from r10r/rcswitch-pi
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- merged pull request r10r#3 - changed swig interface - changed Makefile - added codesend/codesendi utility - added setup.py
- Loading branch information
ScR4tCh
committed
Sep 9, 2015
1 parent
2c9c027
commit bc481f9
Showing
13 changed files
with
4,827 additions
and
728 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,12 @@ | ||
*.o | ||
*~ | ||
*.so | ||
*.cxx | ||
\#* | ||
rcswitch.py | ||
*.pyc | ||
.cproject | ||
.directory | ||
.project | ||
.pydevproject | ||
.settings |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,29 @@ | ||
all: send | ||
CXXFLAGS=-O2 -fPIC | ||
|
||
all: _rcswitch.so send codesend icodesend | ||
|
||
rcswitch_wrap.cxx: RCSwitch.h rcswitch.i | ||
swig -c++ -python rcswitch.i | ||
|
||
rcswitch_wrap.o: rcswitch_wrap.cxx | ||
$(CXX) $(CXXFLAGS) -c $+ -o $@ -I/usr/include/python2.7 | ||
|
||
_rcswitch.so: rcswitch_wrap.o RCSwitch.o | ||
$(CXX) -shared $(LDFLAGS) $+ -o $@ -lwiringPi | ||
|
||
send: RCSwitch.o send.o | ||
$(CXX) $(CXXFLAGS) $(LDFLAGS) $+ -o $@ -lwiringPi | ||
|
||
codesend: RCSwitch.o codesend.o | ||
$(CXX) $(CXXFLAGS) $(LDFLAGS) $+ -o $@ -lwiringPi | ||
|
||
icodesend: RCSwitch.o icodesend.o | ||
$(CXX) $(CXXFLAGS) $(LDFLAGS) $+ -o $@ -lwiringPi | ||
|
||
clean: | ||
$(RM) *.o send | ||
$(RM) *.o *.so *.pyc *.cxx send | ||
|
||
install: | ||
mkdir -p /usr/lib/python2.7/dist-packages | ||
cp rcswitch.py /usr/lib/python2.7/dist-packages | ||
cp _rcswitch.so /usr/lib/python2.7/dist-packages |
Oops, something went wrong.