configure

changeset 4
d8e8f34e65ee
parent 0
804d8803eade
equal deleted inserted replaced
3:c04433993fbb 4:d8e8f34e65ee
350 done 350 done
351 351
352 echo no 352 echo no
353 return 1 353 return 1
354 } 354 }
355 dependency_sqlite()
356 {
357 printf "checking for sqlite... "
358 # dependency sqlite
359 while true
360 do
361 if [ -z "$PKG_CONFIG" ]; then
362 break
363 fi
364 $PKG_CONFIG sqlite3
365 if [ $? -ne 0 ] ; then
366 break
367 fi
368 CFLAGS="$CFLAGS `$PKG_CONFIG --cflags sqlite3`"
369 LDFLAGS="$LDFLAGS `$PKG_CONFIG --libs sqlite3`"
370 echo yes
371 return 0
372 done
373
374 echo no
375 return 1
376 }
355 dependency_gtk3() 377 dependency_gtk3()
356 { 378 {
357 printf "checking for gtk3... " 379 printf "checking for gtk3... "
358 # dependency gtk3 380 # dependency gtk3
359 while true 381 while true
719 fi 741 fi
720 if [ ! -z "${LDFLAGS}" ]; then 742 if [ ! -z "${LDFLAGS}" ]; then
721 echo "TK_LDFLAGS += $LDFLAGS" >> $TEMP_DIR/config.mk 743 echo "TK_LDFLAGS += $LDFLAGS" >> $TEMP_DIR/config.mk
722 fi 744 fi
723 745
746 # Target: note
747 CFLAGS=
748 LDFLAGS=
749 CXXFLAGS=
750
751 dependency_sqlite
752 if [ $? -ne 0 ]; then
753 DEPENDENCIES_FAILED="$DEPENDENCIES_FAILED sqlite "
754 ERROR=1
755 fi
756
757 # Features
758
759
760 echo >> $TEMP_DIR/config.mk
761 if [ ! -z "${CFLAGS}" ]; then
762 echo "NOTE_CFLAGS += $CFLAGS" >> $TEMP_DIR/config.mk
763 fi
764 if [ ! -z "${CXXFLAGS}" ]; then
765 echo "NOTE_CXXFLAGS += $CXXFLAGS" >> $TEMP_DIR/config.mk
766 fi
767 if [ ! -z "${LDFLAGS}" ]; then
768 echo "NOTE_LDFLAGS += $LDFLAGS" >> $TEMP_DIR/config.mk
769 fi
770
724 if [ $ERROR -ne 0 ]; then 771 if [ $ERROR -ne 0 ]; then
725 echo 772 echo
726 echo "Error: Unresolved dependencies" 773 echo "Error: Unresolved dependencies"
727 echo $DEPENDENCIES_FAILED 774 echo $DEPENDENCIES_FAILED
728 rm -Rf $TEMP_DIR 775 rm -Rf $TEMP_DIR

mercurial