Question
I'm an experienced Tizen developer who worked with the platform from 2013 until two years ago. Previously, I was comfortable using C++ as the native language with Tizen SDK. However, upon returning to Tizen development, I notice that:
- All UI samples using EFL are now written in C instead of C++
- The IDE no longer has the "Add new → Add new class" option
- I now need to manually add .h and .cpp files separately
- The IDE shows "error: unknown type name 'class'" when I declare a class
What happened to the C++ support I was familiar with in Tizen?
Answer
Problem Understanding
The confusion stems from Tizen's transition to primarily using C for its native API, particularly for EFL (Enlightenment Foundation Libraries) which is the main UI framework. While C++ is still supported, the default tooling and samples now emphasize C.
Solution Methods
-
Basic C++ Setup in Tizen Studio
- Create .cpp files manually by right-clicking src folder → New → File
- Ensure proper file organization:
- Header files in
incfolder - Source files in
srcfolder
- Header files in
- Configure compiler settings:
- Project Properties → C/C++ Build → Tizen Settings → Select LLVM GCC-4.9/GCC 4.9
- Project Properties → C/C++ Build → Settings → C++ Compiler/Dialect → Set to C++11
-
Alternative C++ Approaches
- Consider using DALi (Dynamic Animation Library) for C++ UI development
- Explore Tizen Fundamental Classes (TFC), a C++ wrapper for Tizen's C API
- Check out App Assist EFL library for more object-oriented C++ development
-
Working with C APIs in C++
- You can still use C++ while calling C-style EFL functions
- Be prepared for more procedural-style code when working with core APIs
Additional Tips
- The Tizen native API is primarily C-based, but C++ is fully supported
- For modern C++ development, consider these resources:
- Samsung is also introducing C# support, which may be worth considering for new projects