March 28, 2024, 20:50
bigger smaller reset     1020px Wide width Full width Reset   * *

Gildor's Forums

  Homepage Facebook Read news on Twitter Youtube channel Github page
Welcome, Guest. Please login or register.
Did you miss your activation email?

« previous next »
Print
Author Topic: Building the code  (Read 10449 times)
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #30 on: March 02, 2018, 10:28 »

I think the title "Building the source code" in readme.md may be confused. (I think it is a guid that make a vs solution! )
No, it's exactly as it says - how to build umodel from source code Smiley
Logged
fdcumt
Newbie
*
Posts: 18


View Profile
« Reply #31 on: March 02, 2018, 10:29 »

Currently UModel uses own build system. There's no way to generate solution. You can make it by yourself, use New | Project, then selecting General | Makefile project. No more hints because I never did that by myself.

I have TODO item to generate solution with this build system (like UE4 build system does) - https://trello.com/c/jqaLmmqY/60-visual-studio-solution
However I'm not sure if I'll do that one day.

Thanks for your reply and the cool project!
I will try to do it by myself!
Logged
someguyplayingfortnite
Guest
« Reply #32 on: May 26, 2018, 00:35 »

Can I use Visual Studio 2017? Because it always gives me an error.
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #33 on: May 26, 2018, 00:39 »

You should use 2013 or 2015.
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #34 on: May 26, 2018, 16:33 »

I've updated BuildTools.zip (vc32tools script inside the archive) so it can locate and use VS2017 now.
Logged
eslindsey
Newbie
*
Posts: 4



View Profile
« Reply #35 on: June 26, 2018, 00:40 »

Debian GNU/Linux 8 (jessie) with gcc and libsdl2-dev installed and up-to-date.
Do I need to do anything else before attempting to compile? The README.md made it look very simple.

Quote
~$ git clone https://github.com/gildor2/UModel.git && cd UModel
Cloning into 'UModel'...
remote: Counting objects: 9904, done.
remote: Compressing objects: 100% (201/201), done.
remote: Total 9904 (delta 209), reused 248 (delta 145), pack-reused 9557
Receiving objects: 100% (9904/9904), 76.43 MiB | 3.35 MiB/s, done.
Resolving deltas: 100% (7907/7907), done.
Checking connectivity... done.
~/UModel$ ./build.sh

...

gcc -pipe -c -msse2 -std=c++0x -fno-strict-aliasing -fno-stack-protector -Wno-invalid-offsetof -Os -D DYNAMIC_CRC_TABLE -D BUILDFIXED -D NO_GZIP -I ./libs/include -o ./obj/libs-unix/inffast.o ./libs/zlib/inffast.c
cc1: warning: command line option '-std=c++11' is valid for C++/ObjC++ but not for C

...

./libs/lzo/miniacc.h:4208:33: note: in expansion of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #  define ACCCHK_ASSERT(expr)   ACC_COMPILE_TIME_ASSERT_HEADER(expr)
                                 ^
./libs/lzo/miniacc.h:4214:9: note: in expansion of macro 'ACCCHK_ASSERT'
         ACCCHK_ASSERT( (type) (~(type)0) ==     (type) (-1) )
         ^
./libs/lzo/miniacc.h:4224:49: note: in expansion of macro 'ACCCHK_ASSERT_SIGN_T'
 #    define ACCCHK_ASSERT_IS_UNSIGNED_T(type)   ACCCHK_ASSERT_SIGN_T(type,>)
                                                 ^
./libs/lzo/lzo_init.c:76:5: note: in expansion of macro 'ACCCHK_ASSERT_IS_UNSIGNED_T'
     ACCCHK_ASSERT_IS_UNSIGNED_T(lzo_xint)
     ^
./libs/lzo/lzo_init.c:77:19: error: expected declaration specifiers or '...' before 'sizeof'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint32))
                   ^
./libs/lzo/lzo_conf.h:117:60: note: in definition of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                            ^
./libs/lzo/lzo_init.c:77:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint32))
     ^
./libs/lzo/lzo_conf.h:117:66: error: expected declaration specifiers or '...' before string constant
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                                  ^
./libs/lzo/miniacc.h:4208:33: note: in expansion of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #  define ACCCHK_ASSERT(expr)   ACC_COMPILE_TIME_ASSERT_HEADER(expr)
                                 ^
./libs/lzo/lzo_init.c:77:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint32))
     ^
./libs/lzo/lzo_init.c:78:19: error: expected declaration specifiers or '...' before 'sizeof'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint))
                   ^
./libs/lzo/lzo_conf.h:117:60: note: in definition of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                            ^
./libs/lzo/lzo_init.c:78:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint))
     ^
./libs/lzo/lzo_conf.h:117:66: error: expected declaration specifiers or '...' before string constant
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                                  ^
./libs/lzo/miniacc.h:4208:33: note: in expansion of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #  define ACCCHK_ASSERT(expr)   ACC_COMPILE_TIME_ASSERT_HEADER(expr)
                                 ^
./libs/lzo/lzo_init.c:78:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) >= sizeof(lzo_uint))
     ^
./libs/lzo/lzo_init.c:79:19: error: expected declaration specifiers or '...' before 'sizeof'
     ACCCHK_ASSERT(sizeof(lzo_xint) == sizeof(lzo_uint32) || sizeof(lzo_xint) == sizeof(lzo_uint))
                   ^
./libs/lzo/lzo_conf.h:117:60: note: in definition of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                            ^
./libs/lzo/lzo_init.c:79:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) == sizeof(lzo_uint32) || sizeof(lzo_xint) == sizeof(lzo_uint))
     ^
./libs/lzo/lzo_conf.h:117:66: error: expected declaration specifiers or '...' before string constant
 #define ACC_COMPILE_TIME_ASSERT_HEADER(expr) static_assert(expr, "Static assertion failed");
                                                                  ^
./libs/lzo/miniacc.h:4208:33: note: in expansion of macro 'ACC_COMPILE_TIME_ASSERT_HEADER'
 #  define ACCCHK_ASSERT(expr)   ACC_COMPILE_TIME_ASSERT_HEADER(expr)
                                 ^
./libs/lzo/lzo_init.c:79:5: note: in expansion of macro 'ACCCHK_ASSERT'
     ACCCHK_ASSERT(sizeof(lzo_xint) == sizeof(lzo_uint32) || sizeof(lzo_xint) == sizeof(lzo_uint))
     ^
Makefile:1606: recipe for target 'obj/libs-unix/lzo_init.o' failed
make: *** [obj/libs-unix/lzo_init.o] Error 1
« Last Edit: June 26, 2018, 00:54 by eslindsey » Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #36 on: June 26, 2018, 12:30 »

I've compiled umodel for 32 and 64 bit linux using gcc 7.1, and got no problems. I can't reproduce your issue.
Logged
eslindsey
Newbie
*
Posts: 4



View Profile
« Reply #37 on: June 26, 2018, 20:00 »

Maybe my gcc is too old, the latest packaged version is 4.9.2. I'll try a newer GCC, thanks for the reply!
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #38 on: June 26, 2018, 21:40 »

GCC 4 is definitely very old.
Logged
eslindsey
Newbie
*
Posts: 4



View Profile
« Reply #39 on: June 27, 2018, 07:55 »

I was hoping to get close enough to gcc 7.1 with Debian's latest stable release 9.4 ("stretch"), which is running gcc (Debian 6.3.0-18+deb9u1) 6.3.0 20170516. Unfortunately, I get a lot of the same compile errors.

I tried to upgrade to Debian's testing release ("buster") but the introduction of systemd crashed my whole VM at boot time, so it looks like it's time for a fresh install.
Logged
eslindsey
Newbie
*
Posts: 4



View Profile
« Reply #40 on: June 30, 2018, 11:11 »

Gildor, I was finally able to compile successfully and easily, but only with "buster" (testing). I guess that's the minimum version of Debian that will compile this code. It comes with gcc (Debian 7.3.0-23) 7.3.0. In addition to libsdl2-dev I also had to install g++, build-essential, and make, which didn't come installed out of the box. Hopefully this helps anyone else trying to build UModel on Debian. Thanks for all the great work!
Logged
FabianFG
Jr. Member
**
Posts: 57


View Profile
« Reply #41 on: September 04, 2018, 21:12 »

I might be dumb but while building umodel using the build.sh I always get this error
"The command rc.exe could not be found"
I would appreciate any help
« Last Edit: September 04, 2018, 22:13 by FunGames » Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #42 on: September 04, 2018, 22:16 »

Which Visual Studio version do you have installed and at which location? The same question about Windows Kit / SDK.
Logged
FabianFG
Jr. Member
**
Posts: 57


View Profile
« Reply #43 on: September 06, 2018, 19:20 »

From everything the newest
Visual Studio 15.8.28010.2016
Windows SDK 10.0.17134.12
Logged
Gildor
Administrator
Hero Member
*****
Posts: 7978



View Profile WWW
« Reply #44 on: September 06, 2018, 19:44 »

I've asked about locations too. Could you please provide me the full build log?
Logged
Print 
« previous next »
Jump to:  

Powered by SMF | SMF © 2006-2009, Simple Machines LLC
Leviathan design by Bloc | XHTML | CSS