Blame docker-builder-data/build/script/packet/synfigstudio-master.sh

ce0d6b
#   jasper       - from gdkpixbuf | jpeg, freeglut
ce0d6b
#   atspi2       - from atspi2atk | glib
ce0d6b
#   gobjectintrospection - from gdkpixbuf | glib
ce0d6b
ce0d6b
# 	atk          - from gtk       | glib
ce0d6b
#   atspi2atk    - from gtk       | atk, atspi2
ce0d6b
# 	gdkpixbuf    - from gtk       | jpeg, png, tiff, jasper, glib, gobjectintrospection
c5973d
#   rsvg         - from gtk,adwa..| xml, gdkpixbuf, cairo, pango
ce0d6b
ce0d6b
# 	gtk          - from gtkmm     | epoxy, rsvg, atk, atspi2atk, gdkpixbuf, cairo, pango
ce0d6b
#   atkmm        - from gtkmm     | atk, glibmm
ce0d6b
#   cairomm      - from gtkmm     | cairo, sigcpp
ce0d6b
#   pangomm      - from gtkmm     | pango, glibmm, cairomm
ce0d6b
ce0d6b
#   synfigcore                    | -
ce0d6b
#   gtkmm                         | gtk, atkmm, cairomm, pangomm
54782b
#   adwaitaicons                  | gtk, rsvg
54782b
#   gnomethemes                   | gtk, rsvg
ce0d6b
6a65b0
DEPS="synfigcore-master"
c35e3a
DEPS_NATIVE="libtool-2.4.6 synfigcore-master"
ce0d6b
6a65b0
if [ "$PLATFORM" = "win" ]; then
6a65b0
    DEPS="$DEPS gtkmm-3.22.0"
6a65b0
else
6a65b0
    DEPS="$DEPS gtkmm-3.14.0"
6a65b0
fi
6a65b0
ce0d6b
PK_DIRNAME="synfig"
ce0d6b
PK_URL="https://github.com/synfig/$PK_DIRNAME.git"
980907
PK_GIT_OPTIONS="--branch testing"
ce0d6b
PK_CPPFLAGS="-std=c++11"
99b145
PK_LICENSE_FILES="synfig-studio/AUTHORS synfig-studio/README"
ce0d6b
99b145
source $INCLUDE_SCRIPT_DIR/inc-pkall-git.sh
ce0d6b
183b24
pkhook_version() {
183b24
    cat "$PK_DIRNAME/synfig-studio/configure.ac" \
183b24
    | grep "AC_INIT" \
183b24
    | cut -d [ -f 3 \
183b24
    | cut -d ] -f 1 \
183b24
    || return 1
183b24
}
183b24
ce0d6b
pkbuild() {
3ec770
    cd "$BUILD_PACKET_DIR/$PK_DIRNAME/synfig-studio" || return 1
3ec770
    if ! check_packet_function $NAME build.configure; then
3ec770
        ./bootstrap.sh || return 1
3ec770
        ./configure \
3ec770
         --host=$HOST \
3ec770
         --prefix=$INSTALL_PACKET_DIR \
3ec770
         --sysconfdir=$INSTALL_PACKET_DIR/etc \
3ec770
        || return 1
3ec770
        set_done $NAME build.configure
3ec770
    fi
3ec770
    make -j${THREADS} || return 1
ce0d6b
}
ce0d6b
ce0d6b
pkinstall() {
ce0d6b
    cd "$BUILD_PACKET_DIR/$PK_DIRNAME/synfig-studio"
ce0d6b
    if ! make install; then
ce0d6b
        return 1
ce0d6b
    fi
94cef0
3ec770
    cd "$INSTALL_PACKET_DIR"
3ec770
    mv "share/pixmaps/synfigstudio/"* "share/pixmaps/"
94cef0
ece819
    # copy system libraries
ece819
    if [ "$PLATFORM" = "win" ]; then
ece819
        local TARGET="$INSTALL_PACKET_DIR/bin/"
ece819
        local LOCAL_DIR="/usr/$HOST/sys-root/mingw/bin/"
ece819
        cp $LOCAL_DIR/libgcc*.dll        "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libstdc*.dll       "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libwinpthread*.dll "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libquadmath*.dll   "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libgfortran*.dll   "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/iconv*.dll         "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libintl*.dll       "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libdl*.dll         "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libltdl*.dll       "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libexpat*.dll      "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/zlib*.dll          "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libbz2*.dll        "$TARGET" || return 1
ece819
        cp $LOCAL_DIR/libfreetype*.dll   "$TARGET" || return 1
ece819
    else
ece819
        local TARGET="$INSTALL_PACKET_DIR/lib/"
ece819
        copy_system_lib libudev          "$TARGET" || return 1
ece819
        copy_system_lib libgfortran      "$TARGET" || return 1
ece819
        copy_system_lib libdb            "$TARGET" || return 1
ece819
        copy_system_lib libpcre          "$TARGET" || return 1
ece819
        copy_system_lib libdirect        "$TARGET" || return 1
ece819
        copy_system_lib libfusion        "$TARGET" || return 1
ece819
        copy_system_lib libbz2           "$TARGET" || return 1
ece819
    fi
ece819
}
ece819
ece819
pkhook_postlicense() {
ece819
    local TARGET="$LICENSE_PACKET_DIR"
ece819
    if [ "$PLATFORM" = "win" ]; then
ece819
        local LOCAL_DIR="/usr/$HOST/sys-root/mingw/bin/"
ece819
        copy_system_license "mingw$ARCH-gcc gcc"   "$TARGET" || return 1
ece819
        copy_system_license mingw$ARCH-winpthreads "$TARGET" || return 1
ece819
        copy_system_license mingw$ARCH-gettext     "$TARGET" || return 1
ece819
        copy_system_license mingw$ARCH-win-iconv   "$TARGET" || return 1
94cef0
        copy_system_license mingw$ARCH-dlfcn       "$TARGET" || return 1
94cef0
        copy_system_license mingw$ARCH-libltdl     "$TARGET" || return 1
94cef0
        copy_system_license mingw$ARCH-expat       "$TARGET" || return 1
94cef0
        copy_system_license mingw$ARCH-bzip2       "$TARGET" || return 1
94cef0
        copy_system_license mingw$ARCH-freetype    "$TARGET" || return 1
ece819
    else
94cef0
        copy_system_license libudev                "$TARGET" || return 1
ece819
        copy_system_license gfortran               "$TARGET" || return 1
94cef0
        copy_system_license libdb                  "$TARGET" || return 1
94cef0
        copy_system_license libpcre                "$TARGET" || return 1
94cef0
        copy_system_license libdirectfb            "$TARGET" || return 1
94cef0
        copy_system_license libbz2                 "$TARGET" || return 1
ece819
    fi
ce0d6b
}