upstream merge
authorJiyoun Park <jy0703.park@samsung.com>
Fri, 29 Jun 2012 05:26:00 +0000 (14:26 +0900)
committerJiyoun Park <jy0703.park@samsung.com>
Fri, 29 Jun 2012 05:26:00 +0000 (14:26 +0900)
Merge remote-tracking branch 'remotes/origin/upstream'

Conflicts:
ChangeLog

Change-Id: Ibbc9edff80b75a0e3d76bfdfc0e9d0b8d44b4258

1  2 
packaging/edje.spec
src/bin/edje_cc.c
src/bin/edje_cc_handlers.c
src/lib/Edje.h
src/lib/edje_calc.c
src/lib/edje_entry.c
src/lib/edje_multisense.c
src/lib/edje_private.h
src/lib/edje_util.c

index d330a46,0000000..9555eeb
mode 100644,000000..100644
--- /dev/null
@@@ -1,89 -1,0 +1,89 @@@
- Version:    1.2.0+svn.72379slp2+build03
 +#sbs-git:slp/pkgs/e/edje edje 1.1.0+svn.69011slp2+build03 96cd9783918ce594c786d12a5107be27aec4d34b
 +Name:       edje
 +Summary:    Complex Graphical Design/Layout Engine
++Version:    1.2.0+svn.73008slp2+build01
 +Release:    1
 +Group:      System/Libraries
 +License:    BSD
 +URL:        http://www.enlightenment.org/
 +Source0:    %{name}-%{version}.tar.gz
 +Requires(post): /sbin/ldconfig
 +Requires(postun): /sbin/ldconfig
 +BuildRequires:  eina-devel
 +BuildRequires:  eet-devel
 +BuildRequires:  embryo-devel
 +BuildRequires:  evas-devel
 +BuildRequires:  ecore-devel
 +BuildRequires:  liblua-devel
 +BuildRequires:  libremix-devel
 +BuildRequires:  libflac-devel
 +BuildRequires:  libsndfile-devel
 +
 +
 +%description
 +Various binaries for use with libedje
 +Edje is a graphical layout and animation library for animated resizable,
 + compressed and scalable themes. It is the theming engine behind
 + Enlightenment DR 0.17.
 + .
 + This package contains the following binaries:
 +  - edje_cc: Compiles EDC files.
 +  - edje_decc: Used to decompile compiled edje files.
 +  - edje_recc: A convenience script to recompile EDC files.
 +
 +%package devel
 +Summary:    Complex Graphical Design/Layout Engine (devel)
 +Group:      Development/Libraries
 +Requires:   %{name} = %{version}-%{release}
 +
 +%description devel
 +Edje is a graphical layout and animation library (devel)
 +
 +%package tools
 +Summary:    Complex Graphical Design/Layout Engine (tools)
 +Group:      Development/Libraries
 +Requires:   %{name} = %{version}-%{release}
 +Provides:   %{name}-bin
 +Obsoletes:  %{name}-bin
 +
 +%description tools
 +Edje is a graphical layout and animation library (tools)
 +
 +%prep
 +%setup -q
 +
 +%build
 +export CFLAGS+=" -fvisibility=hidden -ffast-math -fPIC"
 +export LDFLAGS+=" -fvisibility=hidden -Wl,--hash-style=both -Wl,--as-needed"
 +
 +%autogen --disable-static
 +%configure --disable-static
 +make %{?jobs:-j%jobs}
 +
 +%install
 +rm -rf %{buildroot}
 +%make_install
 +
 +%post -p /sbin/ldconfig
 +
 +%postun -p /sbin/ldconfig
 +
 +%files
 +%defattr(-,root,root,-)
 +%{_libdir}/libedje.so.*
 +%{_libdir}/remix/*.so
 +%{_datadir}/mime/packages/edje.xml
 +%{_libdir}/edje/modules/multisense_factory/*/module.so
 +
 +%files devel
 +%defattr(-,root,root,-)
 +%{_includedir}/edje-1/*.h
 +%{_libdir}/libedje.so
 +%{_libdir}/pkgconfig/edje.pc
 +%exclude /usr/share/edje/examples/*
 +
 +%files tools
 +%defattr(-,root,root,-)
 +%{_bindir}/*
 +%{_libdir}/%{name}/utils/epp
 +%{_datadir}/%{name}/include/edje.inc
@@@ -30,7 -30,7 +30,7 @@@ int        no_save = 0
  int        min_quality = 0;
  int        max_quality = 100;
  int        compress_mode = EET_COMPRESSION_DEFAULT;
--int        threads = 1;
++int        threads = 0;
  
  static void
  main_help(void)
@@@ -248,6 -248,6 +248,7 @@@ main(int argc, char **argv
        exit(-1);
       }
  
++   _on_edjecc = EINA_TRUE;
     using_file(file_in);
  
     if (!edje_init())
Simple merge
diff --cc src/lib/Edje.h
Simple merge
Simple merge
Simple merge
@@@ -20,7 -20,7 +20,7 @@@ typedef struct _Multisense_Dat
  #define BUF_LEN 64
  #define SND_PROCESS_LENGTH 2048
  
--#ifdef HAVE_LIBREMIX
++#ifdef ENABLE_MULTISENSE
  static Ecore_Thread *player_thread = NULL;
  static int command_pipe[2];
  static Eina_Bool pipe_initialized = EINA_FALSE;
@@@ -63,8 -63,8 +63,7 @@@ struct _Edje_Multisense_Sound_Actio
        Edje_Tone_Action tone;
     } type;
  };
--
--#ifdef HAVE_LIBREMIX
++#ifdef ENABLE_MULTISENSE
  static Multisense_Data *
  init_multisense_environment(void)
  {
  
     m = _edje_module_handle_load(ms_factory);
     if (!m) goto err;
--
++#ifdef HAVE_LIBREMIX
     msdata->msenv->remixenv = remix_init();
--
--   multisense_factory_init =
++#endif
++   multisense_factory_init = 
       eina_module_symbol_get(m, "multisense_factory_init");
     if (multisense_factory_init) multisense_factory_init(msdata->msenv);
--
--   msdata->multisense_sound_player_get =
++#ifdef HAVE_LIBREMIX
++   msdata->multisense_sound_player_get = 
       eina_module_symbol_get(m, "multisense_sound_player_get");
     if (!msdata->multisense_sound_player_get) goto err;
  
                                          msdata->player, msdata->player_layer,
                                          REMIX_SAMPLES(0),
                                          REMIX_SAMPLES(REMIX_COUNT_INFINITE));
++#endif
     return msdata;
  
  err:
     if (msdata)
       {
++#ifdef HAVE_LIBREMIX
          if (msdata->deck) remix_destroy(msdata->msenv->remixenv, msdata->deck);
          if (msdata->msenv->remixenv) remix_purge(msdata->msenv->remixenv);
++#endif
          if (msdata->msenv) free(msdata->msenv);
          free(msdata);
       }
  }
  #endif
  
--#ifdef HAVE_LIBREMIX
++#if defined(ENABLE_MULTISENSE) && defined(HAVE_LIBREMIX)
  static RemixBase *
--eet_sound_reader_get(Edje_Multisense_Env *msenv, const char *path, const char *sound_id, const double speed)
++eet_sound_reader_get(Edje_Multisense_Env *msenv, const char *path,
++                     const char *sound_id, const double speed)
  {
     RemixPlugin *sf_plugin = NULL;
     RemixBase * eet_snd_reader = NULL;
  
  
  static RemixBase *
--edje_remix_sample_create(Multisense_Data *msdata, Edje*ed, Edje_Sample_Action *action)
++edje_remix_sample_create(Multisense_Data *msdata, Edje *ed, Edje_Sample_Action *action)
  {
     RemixBase *remix_snd = NULL;
     Edje_Sound_Sample *sample;
  }
  
  static RemixBase *
--edje_remix_tone_create(Multisense_Data *msdata, Edje*ed, Edje_Tone_Action *action)
++edje_remix_tone_create(Multisense_Data *msdata, Edje *ed, Edje_Tone_Action *action)
  {
     Edje_Sound_Tone *tone;
     RemixSquareTone *square = NULL;
@@@ -217,6 -217,6 +220,7 @@@ sound_command_handler(Multisense_Data *
     RemixBase *sound;
  
     if (read(command_pipe[0], &command, sizeof(command)) <= 0) return;
++
     switch (command.action)
       {
        case EDJE_PLAY_SAMPLE:
  }
  #endif
  
--#ifdef HAVE_LIBREMIX
++#ifdef ENABLE_MULTISENSE
  // msdata outside of thread due to thread issues in dlsym etc.
  static Multisense_Data *msdata = NULL;
  
@@@ -254,11 -254,11 +258,12 @@@ _msdata_free(void
  {
     // cleanup msdata outside of thread due to thread issues in dlsym etc.
     if (!msdata) return;
++#ifdef HAVE_LIBREMIX
     //cleanup Remix stuffs
     remix_destroy(msdata->msenv->remixenv, msdata->player);
     remix_destroy(msdata->msenv->remixenv, msdata->deck);
     remix_purge(msdata->msenv->remixenv);
--
++#endif
     free(msdata->msenv);
     free(msdata);
     msdata = NULL;
@@@ -268,9 -268,9 +273,11 @@@ static voi
  _player_job(void *data __UNUSED__, Ecore_Thread *th)
  {
     fd_set wait_fds;
++#ifdef HAVE_LIBREMIX
     RemixBase *sound;
     RemixCount process_len;
--// disable and move outside of thread due to dlsym etc. thread issues
++#endif
++// disable and move outside of thread due to dlsym etc. thread issues   
  //   Multisense_Data * msdata = init_multisense_environment();
  
     if (!msdata) return;
     fcntl(command_pipe[0], F_SETFL, O_NONBLOCK);
     FD_ZERO(&wait_fds);
     FD_SET(command_pipe[0], &wait_fds);
--
++#ifdef HAVE_LIBREMIX
     while (!ecore_thread_check(th))
       {
          if (!msdata->remaining)
       {
          remix_destroy(msdata->msenv->remixenv, sound);
       }
--
++#endif
     close(command_pipe[0]);
     close(command_pipe[1]);
  }
--#endif
  
--#ifdef HAVE_LIBREMIX
  static void
  _player_cancel(void *data __UNUSED__, Ecore_Thread *th __UNUSED__)
  {
     _msdata_free();
     player_thread = NULL;
  }
--#endif
  
--#ifdef HAVE_LIBREMIX
  static void
  _player_end(void *data __UNUSED__, Ecore_Thread *th __UNUSED__)
  {
@@@ -335,7 -335,7 +338,7 @@@ Eina_Boo
  _edje_multisense_internal_sound_sample_play(Edje *ed, const char *sample_name, const double speed)
  {
     ssize_t size = 0;
--#ifdef ENABLE_MULTISENSE
++#if defined(ENABLE_MULTISENSE) && defined(HAVE_LIBREMIX)
     Edje_Multisense_Sound_Action command;
  
     if ((!pipe_initialized) && (!player_thread)) return EINA_FALSE;
@@@ -363,7 -363,7 +366,7 @@@ Eina_Boo
  _edje_multisense_internal_sound_tone_play(Edje *ed, const char *tone_name, const double duration)
  {
     ssize_t size = 0;
--#ifdef ENABLE_MULTISENSE
++#if defined(ENABLE_MULTISENSE) && defined(HAVE_LIBREMIX)
     Edje_Multisense_Sound_Action command;
  
     if ((!pipe_initialized) && (!player_thread)) return EINA_FALSE;
Simple merge
Simple merge