Browse Source

Start using WiringX Lib instead of WirinPi

AGP
root 4 years ago
parent
commit
62ce21c22e
  1. 4
      Projects/la_mojo/la_mojo.vpj
  2. 8
      Projects/la_mojo/makefile
  3. 6
      lib/App/common/hardwareResourceSerialProvider.h

4
Projects/la_mojo/la_mojo.vpj

@ -131,7 +131,7 @@
<Lib File="openssl"/>
<Lib File="opencv4"/>
<Lib File="rdkafka++`"/>
<Lib File="-lwiringPi"/>
<Lib File="-lwiringx"/>
<Lib File="-lliveMedia"/>
<Lib File="-lgroupsock"/>
<Lib File="-lBasicUsageEnvironment"/>
@ -171,7 +171,7 @@
RunFromDir="%rw">
<Exec
CmdLine='g++ %xup -O3 -w %~other -o "%o" %objs'
OtherOptions="-lconfig -lpthread -lelf -lcurses -lcdk -lcurl `pkg-config --libs rdkafka++` -lsqlite3 -s"/>
OtherOptions="-lconfig -lpthread -lelf -lcurses -lcdk -lcurl `pkg-config --libs rdkafka++` -lwiringx -lsqlite3 -s"/>
</Target>
<Target
Name="Build"

8
Projects/la_mojo/makefile

@ -25,8 +25,8 @@ CFG_LIB=-lsqlite3 -lpthread -lssl -lcurl -lm -lcrypto -lconfig -lz \
-lv4l1 -lv4l2 -lhidapi-libusb `pkg-config libavcodec libavdevice \
libavfilter libavformat libavutil libpostproc libswresample \
libswscale --libs` -latomic `pkg-config --libs openssl opencv4 \
rdkafka++` -lwiringPi -lliveMedia -lgroupsock \
-lBasicUsageEnvironment -lUsageEnvironment
rdkafka++` -lwiringx -lliveMedia -lgroupsock -lBasicUsageEnvironment \
-lUsageEnvironment
CFG_OBJ=
COMMON_OBJ=$(OUTDIR)/base64.o $(OUTDIR)/basicCameraInfo.o \
$(OUTDIR)/basicDualThread.o $(OUTDIR)/basicEngine.o \
@ -124,7 +124,7 @@ ALL_OBJ=$(OUTDIR)/base64.o $(OUTDIR)/basicCameraInfo.o \
-lconfig -lz -lv4l1 -lv4l2 -lhidapi-libusb `pkg-config libavcodec \
libavdevice libavfilter libavformat libavutil libpostproc \
libswresample libswscale --libs` -latomic `pkg-config --libs openssl \
opencv4 rdkafka++` -lwiringPi -lliveMedia -lgroupsock \
opencv4 rdkafka++` -lwiringx -lliveMedia -lgroupsock \
-lBasicUsageEnvironment -lUsageEnvironment
COMPILE=g++ -c -x c++ "-DDEBUG" "-D__STDC_CONSTANT_MACROS" "-D_CLIENT_APPLICATION_" "-D_OPENCV_" "-DRASPI_HARDWARE" -O0 -g1 -ggdb -w -Wpointer-arith -std=c++11 -Wno-write-strings -I../../lib/include `pkg-config opencv4 libavcodec libavdevice libavfilter libavformat libavutil libpostproc libswresample libswscale live555 --cflags` -o "$(OUTDIR)/$(*F).o" $(CFG_INC) $<
@ -308,7 +308,7 @@ ALL_OBJ=$(OUTDIR)/base64.o $(OUTDIR)/basicCameraInfo.o \
$(OUTDIR)/xmlParser.o
COMPILE=g++ -c -x c++ "-DSLIM_KERNEL" "-D_THREAD_SAFE" "-D_BSD_SOURCE" "-D_REENTRANT" -O3 -w -Wpointer-arith -std=gnu++11 -I../../lib/include -o "$(OUTDIR)/$(*F).o" $(CFG_INC) $<
LINK=g++ -O3 -w -lconfig -lpthread -lelf -lcurses -lcdk -lcurl `pkg-config --libs rdkafka++` -lsqlite3 -s -o "$(OUTFILE)" $(ALL_OBJ)
LINK=g++ -O3 -w -lconfig -lpthread -lelf -lcurses -lcdk -lcurl `pkg-config --libs rdkafka++` -lwiringx -lsqlite3 -s -o "$(OUTFILE)" $(ALL_OBJ)
# Pattern rules
$(OUTDIR)/%.o : ../../lib/components/object/%.cpp

6
lib/App/common/hardwareResourceSerialProvider.h

@ -23,8 +23,10 @@
#include <termios.h> // POSIX terminal control definitions
#ifdef __arm__
#ifdef RASPI_HARDWARE
#define USE_WIRINGPI
#include <wiringPi.h>
//#define USE_WIRINGPI
//#include <wiringPi.h>
#define USE_WIRINGX
#include <wiringx.h>
#endif
#endif
#endif

Loading…
Cancel
Save