Gradle and build systems for C language

3,483 views
3,385 views

Published on

Gradle and build systems for C language. Explaining basics of Gradle on simple examples. How to add support for Visual Studio or Linux package to build.

Published in: Technology, Education
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
3,483
On SlideShare
0
From Embeds
0
Number of Embeds
2,437
Actions
Shares
0
Downloads
15
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide

Gradle and build systems for C language

  1. 1. Gradle and build systems for C language 28.4.2014 FI MUNI, Brno Juraj Michálek http://georgik.sinusgear.com
  2. 2. Grab the source code https://github.com/georgik/fimuni-c-cpp-examples.git
  3. 3. Who am I?
  4. 4. SDL Gradle CMake Nuget
  5. 5. tiobe.com - programming lang. index
  6. 6. Let’s start with something cool
  7. 7. The Battle for Wesnoth
  8. 8. Multiplatform SDL officially supports Windows, Mac OS X, Linux, iOS, and Android.
  9. 9. SDL versions 1.2 stable - rock solid 2.x development - new features
  10. 10. Some basic concepts
  11. 11. SDL_init(flags) SDL_INIT_TIMER - The timer subsystem SDL_INIT_AUDIO - The audio subsystem SDL_INIT_VIDEO - The video subsystem SDL_INIT_CDROM - The cdrom subsystem SDL_INIT_JOYSTICK - The joystick subsystem SDL_INIT_EVERYTHING - All of the above SDL_INIT_NOPARACHUTE - Prevents SDL from catching fatal signals SDL_INIT_EVENTTHREAD - Runs the event manager in a separate thread
  12. 12. Quit application SDL_quit()
  13. 13. Window SDL_CreateWindow("Hello World!", 100, 100, 640, 480, SDL_WINDOW_SHOWN);
  14. 14. Load bitmap SDL_Surface *bmp = NULL; bmp = SDL_LoadBMP("./smajlik.bmp");
  15. 15. Visual data SDL_Renderer SDL_Texture
  16. 16. Keyboard SDL_PollEvent(SDL_Event *event) event.key.keysym.sym
  17. 17. Timer SDL_TimerID SDL_AddTimer( Uint32 interval, SDL_TimerCallback callback, void* param)
  18. 18. Mouse SDL_GetMouseState(*x, *y);
  19. 19. Text Not implemented
  20. 20. Extensions extension for many languages: C++, Java, Lua, Perl, PHP, Python, Ruby
  21. 21. Made with SDL
  22. 22. Autiomation Evolved
  23. 23. Domain Specific Language
  24. 24. gradle tasks
  25. 25. build.gradle gradle tasks gradle hello
  26. 26. Plugin system ● focussed functionality is added by plugins ● reuse patterns and practices ● avoiding boilerplate build code
  27. 27. C language plugin build.gradle gradle tasks
  28. 28. C build executable Directory structure build.gradle
  29. 29. gradle tasks gradle mE
  30. 30. Linux Windows
  31. 31. Visual Studio plugin
  32. 32. Gradle wrapper Download and prepare infrastructure
  33. 33. Download SDL2 (for VS)
  34. 34. Sources
  35. 35. Toolchains
  36. 36. Helper files for compilers
  37. 37. Build Debian/Ubuntu packages
  38. 38. Gradle Debian Plugin https://github.com/gesellix/gradle-debian-plugin.git
  39. 39. Further Gradle training https://github.com/ysoftdevs/gradle-training
  40. 40. PyGame Power of C and Power of Python http://www.pygame.org
  41. 41. Kivy - crossplatform framework for NUI SDL + PyGame http://kivy.org
  42. 42. Allegro
  43. 43. Allegro 5.1 Win, Lin, Mac iOS, Android http://alleg.sourceforge.net/a5docs/refman/
  44. 44. Initialization al_init();
  45. 45. Graphic environment al_create_display(int w, int h)
  46. 46. NuGet - http://www.nuget.org
  47. 47. Cppcheck
  48. 48. L10N - verify your translations http://www.microsoft.com/Language
  49. 49. Continuous integration
  50. 50. Raspberry Pi
  51. 51. Opportunity for innovative students Bachelor and master thesis @Y Soft Contact person: Andriy.Stetsko@ysoft.com

×