Commit 50407eaf authored by Raine Makelainen's avatar Raine Makelainen

[embedlite-components] Fix build. Fixes JB#36052

If xulrunner is built with-system-pixman, then build
also embedlite-components with-system-pixman
configuration.
parent a8bbaf03
...@@ -19,6 +19,7 @@ AC_PROG_CPP ...@@ -19,6 +19,7 @@ AC_PROG_CPP
PKG_PROG_PKG_CONFIG PKG_PROG_PKG_CONFIG
NSPR_VERSION=4.9.6 NSPR_VERSION=4.9.6
PIXMAN_VERSION=0.19.2
if test "$PYTHON" == ""; then if test "$PYTHON" == ""; then
PYTHON=python PYTHON=python
...@@ -48,12 +49,25 @@ AC_ARG_WITH([system-nspr], ...@@ -48,12 +49,25 @@ AC_ARG_WITH([system-nspr],
] ]
) )
AC_ARG_WITH([system_pixman],
[AS_HELP_STRING([--with-system_pixman],
[Use system installed pixman(default=no)])
]
)
AS_IF([test "x$with_system_nspr" = "xyes"], AS_IF([test "x$with_system_nspr" = "xyes"],
[PKG_CHECK_MODULES([nspr], [nspr >= $NSPR_VERSION], [NSPR=nspr], [PKG_CHECK_MODULES([nspr], [nspr >= $NSPR_VERSION], [NSPR=nspr],
[AC_MSG_ERROR([--with-system-nspr requested but no nspr(>=$NSPR_VERSION) package found]) [AC_MSG_ERROR([--with-system-nspr requested but no nspr(>=$NSPR_VERSION) package found])
]) ])
]) ])
AS_IF([test "x$with_system_pixman" = "xyes"],
[PKG_CHECK_MODULES([pixman], [pixman-1 >= $PIXMAN_VERSION], [PIXMAN=pixman],
[AC_MSG_ERROR([--with-system-pixman requested but no pixman(>=$PIXMAN_VERSION) package found])
])
])
if test "$OBJ_PATH" != ""; then if test "$OBJ_PATH" != ""; then
SDK_DIR=$OBJ_PATH/dist SDK_DIR=$OBJ_PATH/dist
IDL_DIR=$OBJ_PATH/dist/idl IDL_DIR=$OBJ_PATH/dist/idl
...@@ -62,6 +76,11 @@ AS_IF([test "x$with_system_nspr" = "xyes"], ...@@ -62,6 +76,11 @@ AS_IF([test "x$with_system_nspr" = "xyes"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} `pkg-config --cflags-only-I nspr`"], [ENGINE_CFLAGS="${ENGINE_CFLAGS} `pkg-config --cflags-only-I nspr`"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} -I$OBJ_PATH/dist/include/nspr"] [ENGINE_CFLAGS="${ENGINE_CFLAGS} -I$OBJ_PATH/dist/include/nspr"]
) )
AS_IF([test "x$with_system_pixman" = "xyes"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} `pkg-config --cflags-only-I pixman-1`"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} -I$OBJ_PATH/dist/include/pixman"]
)
ENGINE_LIBS="-L$OBJ_PATH/dist/sdk/lib -lxpcomglue_s -lxul" ENGINE_LIBS="-L$OBJ_PATH/dist/sdk/lib -lxpcomglue_s -lxul"
else else
PKG_CHECK_MODULES(ENGINE, libxul $NSPR, PKG_CHECK_MODULES(ENGINE, libxul $NSPR,
...@@ -69,7 +88,16 @@ PKG_CHECK_MODULES(ENGINE, libxul $NSPR, ...@@ -69,7 +88,16 @@ PKG_CHECK_MODULES(ENGINE, libxul $NSPR,
SDK_DIR=`pkg-config --variable=sdkdir libxul` SDK_DIR=`pkg-config --variable=sdkdir libxul`
IDL_DIR=`pkg-config --variable=idldir libxul` IDL_DIR=`pkg-config --variable=idldir libxul`
INCLUDE_DIR=`pkg-config --variable=includedir libxul` INCLUDE_DIR=`pkg-config --variable=includedir libxul`
ENGINE_CFLAGS="$ENGINE_CFLAGS -I$INCLUDE_DIR/nspr"
AS_IF([test "x$with_system_nspr" = "xyes"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} `pkg-config --cflags-only-I nspr`"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} -I$INCLUDE_DIR/nspr"]
)
AS_IF([test "x$with_system_pixman" = "xyes"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} `pkg-config --cflags-only-I pixman-1`"],
[ENGINE_CFLAGS="${ENGINE_CFLAGS} -I$INCLUDE_DIR/pixman"]
)
]) ])
fi fi
AC_SUBST(SDK_DIR) AC_SUBST(SDK_DIR)
......
...@@ -26,6 +26,7 @@ URL: https://github.com/tmeshkova/embedlite-components ...@@ -26,6 +26,7 @@ URL: https://github.com/tmeshkova/embedlite-components
Source0: %{name}-%{version}.tar.bz2 Source0: %{name}-%{version}.tar.bz2
BuildRequires: xulrunner-qt5-devel >= %{min_xulrunner_version} BuildRequires: xulrunner-qt5-devel >= %{min_xulrunner_version}
BuildRequires: pkgconfig(nspr) BuildRequires: pkgconfig(nspr)
BuildRequires: pkgconfig(pixman-1)
BuildRequires: python BuildRequires: python
BuildRequires: libtool BuildRequires: libtool
BuildRequires: automake BuildRequires: automake
...@@ -43,7 +44,7 @@ EmbedLite Components required for embeded browser UI ...@@ -43,7 +44,7 @@ EmbedLite Components required for embeded browser UI
%build %build
NO_CONFIGURE=yes ./autogen.sh NO_CONFIGURE=yes ./autogen.sh
%configure --with-system-nspr %configure --with-system-nspr --with-system-pixman
make %{?jobs:-j%jobs} make %{?jobs:-j%jobs}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment