Upgrade to new build system
This commit is contained in:
parent
6a64114854
commit
a24c6ae302
3
README
3
README
|
@ -9,6 +9,7 @@ Really Quick Instructions
|
|||
|
||||
To build: ./make.sh
|
||||
To install: ./make.sh install
|
||||
(you might want to set PREFIX, by default it's /usr/local)
|
||||
|
||||
You might want to edit 'config' first.
|
||||
|
||||
@TODO@
|
||||
|
|
|
@ -0,0 +1,19 @@
|
|||
# libiso8601/config
|
||||
# kate: replace-trailing-space-save true; space-indent true; tab-width 4;
|
||||
# vim: expandtab:ts=4:sw=4
|
||||
#
|
||||
# (c)2006, Laurence Withers, <l@lwithers.me.uk>.
|
||||
# Released under the GNU GPLv2. See file COPYING or
|
||||
# http://www.gnu.org/copyleft/gpl.html for details.
|
||||
#
|
||||
# This file contains options used to build libiso8601.
|
||||
#
|
||||
|
||||
[ -z "${PREFIX}" ] && PREFIX="/usr/local"
|
||||
[ -z "${CC}" ] && CC="gcc"
|
||||
[ -z "${CFLAGS}" ] && CFLAGS="-g -O2 -W -Wall"
|
||||
[ -z "${BINDIR}" ] && BINDIR="${PREFIX}/bin"
|
||||
[ -z "${LIBDIR}" ] && LIBDIR="${PREFIX}/lib"
|
||||
[ -z "${INCLUDEDIR}" ] && INCLUDEDIR="${PREFIX}/include"
|
||||
[ -z "${FINALLIBDIR}" ] && FINALLIBDIR="${LIBDIR}"
|
||||
[ -z "${FINALINCLUDEDIR}" ] && FINALINCLUDEDIR="${INCLUDEDIR}"
|
28
make.sh
28
make.sh
|
@ -8,25 +8,14 @@
|
|||
|
||||
|
||||
# This file is the script used to build libiso8601. There are some
|
||||
# options that can be edited; these are set below (or you can pass them
|
||||
# in as variables).
|
||||
[ -z "${CC}" ] && CC="gcc"
|
||||
[ -z "${CXX}" ] && CXX="g++"
|
||||
[ -z "${CFLAGS}" ] && CFLAGS="-g -O2 -W -Wall"
|
||||
[ -z "${PREFIX}" ] && PREFIX="/usr/local"
|
||||
[ -z "${LIBDIR}" ] && LIBDIR="${PREFIX}/lib"
|
||||
[ -z "${BINDIR}" ] && BINDIR="${PREFIX}/bin"
|
||||
[ -z "${INCLUDEDIR}" ] && INCLUDEDIR="${PREFIX}/include"
|
||||
[ -z "${DOCSDIR}" ] && DOCSDIR="${PREFIX}/share/doc/libiso8601"
|
||||
|
||||
# for pkg-config
|
||||
[ -z "${PKGCONFDIR}" ] && PKGCONFDIR="${LIBDIR}/pkgconfig"
|
||||
[ -z "${FINALLIBDIR}" ] && FINALLIBDIR="${LIBDIR}"
|
||||
[ -z "${FINALINCLUDEDIR}" ] && FINALINCLUDEDIR="${INCLUDEDIR}"
|
||||
|
||||
# for SDCC-built firmware
|
||||
[ -z "${HEXDIR}" ] && HEXDIR="${PREFIX}/share/firmware"
|
||||
[ -z "${SDCC}" ] && SDCC="sdcc"
|
||||
# options that can be edited; these are set in the file 'config' (or you
|
||||
# can pass them in as environment variables).
|
||||
if [ ! -e "config" ]
|
||||
then
|
||||
echo "Configuration file not found???"
|
||||
exit 1
|
||||
fi
|
||||
source "config" # don't fail on error, since last command in config might return false
|
||||
|
||||
|
||||
|
||||
|
@ -272,6 +261,7 @@ do
|
|||
echo "Cleaning..."
|
||||
rm -rf ${OUTPUT_DIRS}
|
||||
print_success "Done"
|
||||
true
|
||||
;;
|
||||
|
||||
# bad Kdevelop! bad!
|
||||
|
|
|
@ -1,12 +1,13 @@
|
|||
build.c++.app
|
||||
build.c++.lib
|
||||
build.c++.qtapp
|
||||
build.c++.tests
|
||||
build.c.app
|
||||
build.c.lib
|
||||
build.c.tests
|
||||
build.doxygen.docs
|
||||
build.none.files
|
||||
build.sdcc.firmware
|
||||
build.app.c
|
||||
build.app.c++
|
||||
build.app.c++-qt
|
||||
build.docs.doxygen
|
||||
build.files.none
|
||||
build.firmware.gpasm
|
||||
build.firmware.sdcc
|
||||
build.lib.c
|
||||
build.lib.c++
|
||||
build.tests.c
|
||||
build.tests.c++
|
||||
module-create.sh
|
||||
release.sh
|
||||
|
|
|
@ -1 +1 @@
|
|||
c lib libiso8601 iso8601.h
|
||||
lib c libiso8601 iso8601.h
|
||||
|
|
|
@ -2,7 +2,7 @@ build_target libiso8601
|
|||
|
||||
# make paths (this is for Gentoo in particular)
|
||||
build_dir_tree "${LIBDIR}" || return 1
|
||||
build_dir_tree "${PKGCONFDIR}" || return 1
|
||||
build_dir_tree "${BINDIR}" || return 1
|
||||
build_dir_tree "${INCLUDEDIR}" || return 1
|
||||
|
||||
# install library
|
||||
|
@ -20,16 +20,20 @@ install_symlink "${BASE}" "${MAJOR}" "${LIBDIR}"
|
|||
echo "Installing header file '${libiso8601_HEADER}' into ${INCLUDEDIR}"
|
||||
install_header ${libiso8601_HEADER} ${INCLUDEDIR} 0644 || return 1
|
||||
|
||||
# install pkgconfig file
|
||||
echo "Installing package config file into ${PKGCONFDIR}"
|
||||
PKGCONFFILE=${PKGCONFDIR}/libiso8601.pc
|
||||
do_cmd rm -f ${PKGCONFFILE}
|
||||
do_cmd_redir ${PKGCONFFILE} sed \
|
||||
# install config script
|
||||
echo "Installing config script into ${BINDIR}"
|
||||
CONFFILE="${BINDIR}/libiso8601-config"
|
||||
|
||||
do_cmd rm -f "${CONFFILE}"
|
||||
do_cmd_redir "${CONFFILE}" sed \
|
||||
-e "s,@VERSION@,${VERSION}," \
|
||||
-e "s,@LIBDIR@,${FINALLIBDIR}," \
|
||||
-e "s,@INCLUDEDIR@,${FINALINCLUDEDIR}," \
|
||||
src/libiso8601/pkgconf.in
|
||||
do_cmd chmod 0644 ${PKGCONFFILE}
|
||||
-e "s,@DEP_CFLAGS@,${libiso8601_DEP_CFLAGS}," \
|
||||
-e "s,@DEP_LIBS@,${libiso8601_DEP_LIBS}," \
|
||||
-e "s,@LIB_DIR@,${FINALLIBDIR}," \
|
||||
-e "s,@INCLUDE_DIR@,${FINALINCLUDEDIR}," \
|
||||
src/libiso8601/config-script
|
||||
|
||||
do_cmd chmod 0755 "${CONFFILE}"
|
||||
print_success "Done"
|
||||
|
||||
# kate: replace-trailing-space-save true; space-indent true; tab-width 4;
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
# libiso8601_BUILT
|
||||
# libiso8601_HEADER
|
||||
# libiso8601_BASE
|
||||
# libiso8601_DEP_CFLAGS
|
||||
# libiso8601_DEP_LIBS
|
||||
|
||||
if [ -z ${libiso8601_BUILT} ]
|
||||
then
|
||||
|
@ -10,7 +12,9 @@ then
|
|||
source src/libiso8601/soversion
|
||||
|
||||
libiso8601="obj/${libiso8601_BASE}.so.${SOMAJOR}.${SOMINOR}.${SOMICRO}"
|
||||
SO_EXTRA="-lrt -lc"
|
||||
libiso8601_DEP_CFLAGS=""
|
||||
libiso8601_DEP_LIBS=""
|
||||
SO_EXTRA="${libiso8601_DEP_CFLAGS} ${libiso8601_DEP_LIBS} -lrt -lc"
|
||||
|
||||
echo "Building library ${libiso8601}..."
|
||||
|
||||
|
|
|
@ -1 +1 @@
|
|||
c tests tests libiso8601
|
||||
tests c tests libiso8601
|
||||
|
|
Loading…
Reference in New Issue