find the extension of the shared libraries at configure time

SVN revision: 43267
This commit is contained in:
Vincent Torri 2009-10-25 12:46:49 +00:00
parent b263f7cd23
commit 959022991c
2 changed files with 7 additions and 6 deletions

View File

@ -45,6 +45,11 @@ case "$host_os" in
;;
esac
AC_SUBST(release_info)
AC_SUBST(MODULE_ARCH)
AC_DEFINE_UNQUOTED(MODULE_ARCH, "$MODULE_ARCH", "Module architecture")
EFL_SHARED_EXTENSION="${shrext_cmds}"
AC_DEFINE_UNQUOTED(EFL_SHARED_EXTENSION, "${EFL_SHARED_EXTENSION}", "Shared extension")
requirement_elm=""
@ -242,10 +247,6 @@ AC_SUBST(requirement_elm)
EFL_CHECK_DOXYGEN([build_doc="yes"], [build_doc="no"])
MODULE_ARCH="$host_os-$host_cpu-$release"
AC_SUBST(MODULE_ARCH)
AC_DEFINE_UNQUOTED(MODULE_ARCH, "$MODULE_ARCH", "Module architecture")
AC_OUTPUT([
Makefile
elementary.pc

View File

@ -48,7 +48,7 @@ _elm_module_add(const char *name)
if (home)
{
snprintf(buf, sizeof(buf), "%s/.elementary/modules/%s/%s/module.so", home, name, MODULE_ARCH);
snprintf(buf, sizeof(buf), "%s/.elementary/modules/%s/%s/module" EFL_SHARED_EXTENSION, home, name, MODULE_ARCH);
m->handle = dlopen(buf, RTLD_NOW | RTLD_GLOBAL);
if (m->handle)
{
@ -73,7 +73,7 @@ _elm_module_add(const char *name)
}
if (!m->handle)
{
snprintf(buf, sizeof(buf), "%s/elementary/modules/%s/%s/module.so", _elm_lib_dir, name, MODULE_ARCH);
snprintf(buf, sizeof(buf), "%s/elementary/modules/%s/%s/module" EFL_SHARED_EXTENSION, _elm_lib_dir, name, MODULE_ARCH);
m->handle = dlopen(buf, RTLD_NOW | RTLD_GLOBAL);
if (m->handle)
{