Omnimaga

Calculator Community => TI Calculators => ASM => Topic started by: Streetwalrus on April 16, 2014, 01:01:29 pm

Title: [SOLVED] SPASM not building on Linux x64
Post by: Streetwalrus on April 16, 2014, 01:01:29 pm
This problem is now solved. If you want SPASM, just use the 7zip archive provided by Chickendude (http://www.mirari.fr/wo0H).
Just run make clean then make.

Spoiler For Original post:
Not really sure it actually belongs in here, but I rarely post in the support forum.


I'm trying to compile the latest SPASM revision on ArchLinux (64bit) but I get some error when running make :
Code: [Select]
g++ -I.  -DUSE_REUSABLES -DUSE_GMP -DUNIXVER -DUSE_BUILTIN_FCREATE -c main.cpp
In file included from storage.h:5:0,
                 from main.cpp:7:
hash.h:29:31: erreur: expected template-name before ‘<’ token
   : public std::unary_function<const char *, size_t>
                               ^
hash.h:29:31: erreur: expected ‘{’ before ‘<’ token
hash.h:29:31: erreur: expected unqualified-id before ‘<’ token
Makefile:10: recipe for target 'main.o' failed
make: *** [main.o] Error 1

I'm an 31337 C++ n00b so I don't know what to do about that at all. The PKGBUILD available in the AUR compiles fine but it is an old revision which segfaults when I include bitmaps, which is what I absolutely need right now. After some quick googling I know that it's been fixed ages ago but  I can't use it. :/

Here's the SVN link : https://wabbit.svn.codeplex.com/svn/Wabbitstudio/Source/SPASM (https://wabbit.svn.codeplex.com/svn/Wabbitstudio/Source/SPASM)
Title: Re: SPASM build error
Post by: TheMachine02 on April 16, 2014, 01:06:52 pm
mmhhh... I'll go for a missing space between unary_function and the "<" token
(in file hash.h)
However,  I can't try it right now, so I am not sure if this will works  :/
 
Title: Re: SPASM build error
Post by: Streetwalrus on April 16, 2014, 01:10:15 pm
Nope it was not the space.
Title: Re: SPASM build error
Post by: TheMachine02 on April 16, 2014, 01:31:56 pm
you could always try this : http://ti-84-plus.com/blog/spasm-on-linux-64bits-how-to-install-and-fix-common-issues/ (http://ti-84-plus.com/blog/spasm-on-linux-64bits-how-to-install-and-fix-common-issues/)
EDIT: or this http://www.cemetech.net/forum/viewtopic.php?t=9907&start=0 (http://www.cemetech.net/forum/viewtopic.php?t=9907&start=0)
Title: Re: SPASM build error
Post by: Streetwalrus on April 16, 2014, 01:49:57 pm
Never mind actually. It seems that Brass is prefered over SPASM so I'll try that. At first I didn't want to because C# = D: but w/e. Actually I decided again not to try it. I'll just use Sourcecoder to convert my BMPs and I should get around to writing my own assembler in Python eventually.

Or even better : I'll make my own Python script for what I want to do. It'll be faster and more fun.
Title: Re: SPASM build error
Post by: chickendude on April 16, 2014, 07:08:09 pm
I modified the sources for it to compile under (64-bit) Linux, see if this works better for you:
http://www.mirari.fr/wo0H

I made a patch and sent it to Buckeye Dude, they said they'd put it in. There are a couple parts that tried to use Windows functions that needed to be commented out/#if'd around and you need to add some includes:
Quote
You'll need to add #include <functional> and #include <unordered_map> at the top (under #include "list.h"). [In hash.h]
You'll also need to add the flag:
-std=c++11
..to g++ in the makefile:
CXXFLAGS+= -I. -DUSE_REUSABLES -DUSE_GMP -DUNIXVER -DUSE_BUILTIN_FCREATE -std=c++11
Title: Re: SPASM build error
Post by: Streetwalrus on April 17, 2014, 03:22:47 am
Well, thank you very much I'm trying like now. :)
Edit : It compiled, so yay ! :D
I'll edit the first post.