Ninja compilation problems

Hello, I was trying to compile the source code for the linux version of Aseprite for use on a raspberry pi (3 b+) running Ubuntu Mate, and followed this (How to Compile Aseprite on Ubuntu Linux - YouTube) tutorial. I was successful, all the way up to when I had to do the final compilation with ninja. It stopped and this is the final few lines of the output:

ninja: build stopped: subcommand failed.```

If you need any more information, let me know.

1 Like

You can get aseprite working on a pi that’s epic welcome to the community (:slight_smile:

1 Like

No, the problem is that I can’t quite get it working. Do you have any idea on how to fix the problem mentioned in the original post?

1 Like

Oh that’s a shame sadly I have no idea

ok, so I’ve traced the problem down to what seems to be its source, and that is the compilation of skia. I go through all of the steps listed on the github page (GitHub - aseprite/skia: Skia is a complete 2D graphic library for drawing Text, Geometries, and Images.), and everything seems to work fine, up until this step:
gn gen out/Release-x64 --args="is_debug=false is_official_build=true skia_use_system_expat=false skia_use_system_icu=false skia_use_system_libjpeg_turbo=false skia_use_system_libpng=false skia_use_system_libwebp=false skia_use_system_zlib=false"

I run that, and this is the error message that pops up:
Traceback (most recent call last): File "/home/cade/deps/depot_tools/", line 75, in <module> sys.exit(main(sys.argv)) File "/home/cade/deps/depot_tools/", line 70, in main return[gn_path] + args[1:]) File "/usr/lib/python2.7/", line 172, in call return Popen(*popenargs, **kwargs).wait() File "/usr/lib/python2.7/", line 394, in __init__ errread, errwrite) File "/usr/lib/python2.7/", line 1047, in _execute_child raise child_exception OSError: [Errno 8] Exec format error

Any help would be appreciated, maybe @dacap could help?

1 Like

Ok, nevermind, I fixed that by just using the pre-compiled version of skia, and then the compilation part worked fine, but now whenever I run ninja aseprite I get this:
[109/1496] Building C object third_par...rl/lib/CMakeFiles/libcurl.dir/file.c.o FAILED: third_party/curl/lib/CMakeFiles/libcurl.dir/file.c.o /usr/bin/cc -DBUILDING_LIBCURL -DCMARK_STATIC_DEFINE -DHAVE_CONFIG_H -DNDEBUG -DPNG_NO_MMX_CODE -I../third_party/zlib -Ithird_party/zlib -I../third_party/libpng -Ithird_party/libpng -I../third_party/libwebp/src -I../third_party/tinyxml -I../third_party/pixman/pixman -I. -I../third_party/freetype2/include -I../third_party/harfbuzz/src -I../third_party/giflib/lib -I../third_party/jpeg -Ithird_party/cmark -I../third_party/curl/include -I../third_party/simpleini -I../third_party/. -Ithird_party/curl/include/curl -Ithird_party/curl/lib/../include -I../third_party/curl/lib/.. -I../third_party/curl/lib/../include -Ithird_party/curl/lib/.. -I../third_party/curl/lib -Ithird_party/curl/lib -O2 -g -DNDEBUG -MD -MT third_party/curl/lib/CMakeFiles/libcurl.dir/file.c.o -MF third_party/curl/lib/CMakeFiles/libcurl.dir/file.c.o.d -o third_party/curl/lib/CMakeFiles/libcurl.dir/file.c.o -c ../third_party/curl/lib/file.c In file included from ../third_party/curl/lib/setup.h:126, from ../third_party/curl/lib/file.c:23: ../third_party/curl/include/curl/curlrules.h:79:4: error: #error "CURL_SIZEOF_LONG definition is missing!" 79 | # error "CURL_SIZEOF_LONG definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:80:4: error: unknown type name ‘Error’ 80 | Error Compilation_aborted_CURL_SIZEOF_LONG_is_missing | ^~~~~ ../third_party/curl/include/curl/curlrules.h:94:4: error: #error "CURL_TYPEOF_CURL_OFF_T definition is missing!" 94 | # error "CURL_TYPEOF_CURL_OFF_T definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:95:4: error: expected ‘=’, ‘,’, ‘;’, ‘asm’ or ‘__attribute__’ before ‘Error’ 95 | Error Compilation_aborted_CURL_TYPEOF_CURL_OFF_T_is_missing | ^~~~~ ../third_party/curl/include/curl/curlrules.h:95:4: error: unknown type name ‘Error’ ../third_party/curl/include/curl/curlrules.h:99:4: error: #error "CURL_FORMAT_CURL_OFF_T definition is missing!" 99 | # error "CURL_FORMAT_CURL_OFF_T definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:104:4: error: #error "CURL_FORMAT_CURL_OFF_TU definition is missing!" 104 | # error "CURL_FORMAT_CURL_OFF_TU definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:109:4: error: #error "CURL_FORMAT_OFF_T definition is missing!" 109 | # error "CURL_FORMAT_OFF_T definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:114:4: error: #error "CURL_SIZEOF_CURL_OFF_T definition is missing!" 114 | # error "CURL_SIZEOF_CURL_OFF_T definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:119:4: error: #error "CURL_SUFFIX_CURL_OFF_T definition is missing!" 119 | # error "CURL_SUFFIX_CURL_OFF_T definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:124:4: error: #error "CURL_SUFFIX_CURL_OFF_TU definition is missing!" 124 | # error "CURL_SUFFIX_CURL_OFF_TU definition is missing!" | ^~~~~ ../third_party/curl/include/curl/curlrules.h:153:18: error: ‘curl_off_t’ undeclared here (not in a function); did you mean ‘loff_t’? 153 | [CurlchkszEQ(curl_off_t, CURL_SIZEOF_CURL_OFF_T)]; | ^~~~~~~~~~ ../third_party/curl/include/curl/curlrules.h:132:34: note: in definition of macro ‘CurlchkszEQ’ 132 | #define CurlchkszEQ(t, s) sizeof(t) == s ? 1 : -1 | ^ ../third_party/curl/include/curl/curlrules.h:153:30: error: ‘CURL_SIZEOF_CURL_OFF_T’ undeclared here (not in a function); did you mean ‘CURL_SIZEOF_CURL_SOCKLEN_T’? 153 | [CurlchkszEQ(curl_off_t, CURL_SIZEOF_CURL_OFF_T)]; | ^~~~~~~~~~~~~~~~~~~~~~ ../third_party/curl/include/curl/curlrules.h:132:40: note: in definition of macro ‘CurlchkszEQ’ 132 | #define CurlchkszEQ(t, s) sizeof(t) == s ? 1 : -1 | ^ [114/1496] Building C object third_par...ib/CMakeFiles/zlibstatic.dir/inflate.o ninja: build stopped: subcommand failed.

If anyone could help, ive been working on this for a few days now, and will appreciate any help I can get.
(The reason Im not just buying it is because the trial versions dont work on my raspberry pi, which is pretty much my only computer at the moment. I do plan on buying it later though, especially if i can get this to work.)

Ok, I was able to get it working by simply installing a fresh raspbian, and it is part of the default repo, however, it seems to be a very outdated version(1.1.9 or something like that.). The changelog in the program itself has the changelog for the latest version, but when I run aseprite --version, it gives a version number of 1. something. Does anybody know how I could update to the latest version, or tell if I am actually on the latest version?

1 Like

@dacap would you guys consider making a raspberry pi version(armv8 I believe) of aseprite available for purchase? I would love that if you could. The current only way I can find to use aseprite on a raspberry pi is through the default repo, which is a very outdated version(1.1.6-dev I think), and missing a lot of features that I need. I have tried to compile it from source, but it throws a lot of errors last I tried.

Hi, I actually just got it working. you will need to define the macros in third_party/curl in the aseprite repo, specifically in curlrules.h, instead of an error you define what the format should be and what the string, integer or type should be.
The other issue is typedef of curl_off_t, I gave this the same type as long.

I was hoping to remove curl completely but, application needs it for newspost as far as I can tell. I didn’t consider this to be a serious issue if I got the types wrong, apparently I didn’t :stuck_out_tongue:

This got compiled on the v1.25 tag on a pi4. beware you it does take some time to compile if you are doing it on the host.

If you have a follow up, happy to talk about this over private messages.