Add a couple things to TODO list so I don't forget (TODO.txt)
[pandora-libraries.git] / Makefile
index 542fee6..fa52006 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -5,7 +5,7 @@
 
 # tools
 CC = ${CROSSCOMPILE}gcc
-CXX = ${CROSSCOMPILE}gcc
+CXX = ${CROSSCOMPILE}g++
 AR = ${CROSSCOMPILE}ar
 RANLIB = ${CROSSCOMPILE}ranlib
 RM = rm
@@ -21,12 +21,12 @@ LIB = libpnd.a
 SOLIB = libpnd.so.1         # canonicle name
 SOLIB1 = libpnd.so.1.0.1    # versioned name
 XMLOBJ = lib/tinyxml/tinystr.o lib/tinyxml/tinyxml.o lib/tinyxml/tinyxmlerror.o lib/tinyxml/tinyxmlparser.o
-ALLOBJ = pnd_conf.o pnd_container.o pnd_discovery.o pnd_pxml.o pnd_notify.o pnd_locate.o pnd_tinyxml.o pnd_pndfiles.o pnd_apps.o pnd_utility.o pnd_desktop.o
+ALLOBJ = pnd_conf.o pnd_container.o pnd_discovery.o pnd_pxml.o pnd_notify.o pnd_locate.o pnd_tinyxml.o pnd_pndfiles.o pnd_apps.o pnd_utility.o pnd_desktop.o pnd_io_gpio.o pnd_logger.o
 
-all: ${SOLIB} ${LIB} conftest discotest notifytest locatetest pndnotifyd rawpxmltest
+all: ${SOLIB} ${LIB} conftest discotest notifytest pndnotifyd rawpxmltest pndvalidator loggertest pnd_run
 
 clean:
-       ${RM} -f ${ALLOBJ} ${XMLOBJ} ${LIB} ${SOLIB1} locatetest.o bin/locatetest conftest.o bin/conftest discotest.o bin/discotest bin/notifytest notifytest.o bin/rawpxmltest rawpxmltest.o bin/pndnotifyd pndnotifyd.o ${SOLIB} testdata/dotdesktop/*.desktop testdata/apps/*.pnd testdata/dotdesktop/*.png deployment/usr/lib/libpnd* deployment/usr/bin/pndnotifyd deployment/usr/pandora/scripts/* deployment/etc/sudoers deployment/etc/init.d/pndnotifyd
+       ${RM} -f ${ALLOBJ} ${XMLOBJ} ${LIB} ${SOLIB1} locatetest.o bin/locatetest conftest.o bin/conftest discotest.o bin/discotest loggertest.o bin/loggertest bin/notifytest notifytest.o bin/rawpxmltest rawpxmltest.o bin/pnd_run pnd_run.o bin/pndnotifyd pndnotifyd.o ${SOLIB} testdata/dotdesktop/*.desktop testdata/menu/*.desktop testdata/apps/*.pnd testdata/dotdesktop/*.png deployment/usr/lib/libpnd* deployment/usr/bin/pndnotifyd deployment/usr/bin/pnd_run deployment/usr/pandora/scripts/* deployment/etc/sudoers deployment/etc/init.d/pndnotifyd bin/pndvalidator pndvalidator.o
        ${RM} -rf deployment/media
        find . -name "*~*" -exec rm {} \; -print
 
@@ -41,9 +41,19 @@ libpnd.so.1: ${ALLOBJ} ${XMLOBJ}
        ${CC} -shared -Wl,-soname,${SOLIB} -o ${SOLIB1} ${ALLOBJ} ${XMLOBJ}
        ln -f -s ${SOLIB1} ${SOLIB}
 
+${SOLIB1}:     ${ALLOBJ} ${XMLOBJ}
+       ${CC} -shared -Wl,-soname,${SOLIB} -o ${SOLIB1} ${ALLOBJ} ${XMLOBJ}
+       ln -f -s ${SOLIB1} ${SOLIB}
+
 pndnotifyd:    pndnotifyd.o ${SOLIB1}
        ${CC} -lstdc++ -o bin/pndnotifyd pndnotifyd.o ${SOLIB1}
 
+pndvalidator:  pndvalidator.o ${SOLIB1}
+       ${CC} -lstdc++ -o bin/pndvalidator pndvalidator.o ${SOLIB1}
+
+pnd_run:       pnd_run.o ${SOLIB1}
+       ${CC} -lstdc++ -o bin/pnd_run pnd_run.o ${SOLIB1}
+
 # deployment and assembly components
 #
 
@@ -68,6 +78,7 @@ deploy:
        # copy in goodies
        cp libpnd* deployment/usr/lib
        cp bin/pndnotifyd deployment/usr/bin
+       cp bin/pnd_run deployment/usr/bin
        cp testdata/scripts/* deployment/usr/pandora/scripts
        # copy in freebee .pnd apps to /usr/pandora/apps
        # add pndnotify to etc/rc/startup-whatever
@@ -91,3 +102,6 @@ locatetest:  locatetest.o ${SOLIB1}
 
 rawpxmltest:    rawpxmltest.o ${LIB}
        ${CC} -lstdc++ -o bin/rawpxmltest rawpxmltest.o ${LIB}
+
+loggertest:    loggertest.o ${LIB}
+       ${CC} -lstdc++ -o bin/loggertest loggertest.o libpnd.a