• There is NO official Otland's Discord server and NO official Otland's server list. The Otland's Staff does not manage any Discord server or server list. Moderators or administrator of any Discord server or server lists have NO connection to the Otland's Staff. Do not get scammed!
  • 2026 staff recruitment is open! Check it out and consider applying!

Compiling compiling in ubuntu 64 OS

seleo

Active Member
Joined
Jun 6, 2012
Messages
498
Reaction score
33
Location
Egypt
Hello
i get this error when i edit the source
PHP:
The Forgotten Server build script -
Using ccache
CCache binaries located in /usr/lib/ccache

Start building on 2 cores, using 3 processes

make  all-am
make[1]: Entering directory `/var/project/source-original'
g++ -DHAVE_CONFIG_H -I.    -I/usr/include/libxml2  -I/usr/include/lua5.2    -D__USE_MYSQL__  -D__WAR_SYSTEM__ -D__ENABLE_SERVER_DIAGNOSTIC__ -D_THREAD_SAFE -D_REENTRANT -Wall -ggdb -O1 -march=native -mtune=native -MT actions.o -MD -MP -MF .deps/actions.Tpo -c -o actions.o actions.cpp
g++ -DHAVE_CONFIG_H -I.    -I/usr/include/libxml2  -I/usr/include/lua5.2    -D__USE_MYSQL__  -D__WAR_SYSTEM__ -D__ENABLE_SERVER_DIAGNOSTIC__ -D_THREAD_SAFE -D_REENTRANT -Wall -ggdb -O1 -march=native -mtune=native -MT allocator.o -MD -MP -MF .deps/allocator.Tpo -c -o allocator.o allocator.cpp
g++ -DHAVE_CONFIG_H -I.    -I/usr/include/libxml2  -I/usr/include/lua5.2    -D__USE_MYSQL__  -D__WAR_SYSTEM__ -D__ENABLE_SERVER_DIAGNOSTIC__ -D_THREAD_SAFE -D_REENTRANT -Wall -ggdb -O1 -march=native -mtune=native -MT baseevents.o -MD -MP -MF .deps/baseevents.Tpo -c -o baseevents.o baseevents.cpp
baseevents.cpp:1:0: error: CPU you selected does not support x86-64 instruction set
make[1]: *** [baseevents.o] Error 1
make[1]: *** Waiting for unfinished jobs....
allocator.cpp:1:0: error: CPU you selected does not support x86-64 instruction set
make[1]: *** [allocator.o] Error 1
actions.cpp:1:0: error: CPU you selected does not support x86-64 instruction set
make[1]: *** [actions.o] Error 1
make[1]: Leaving directory `/var/project/source-original'
make: *** [all] Error 2

this my first time i see this error
is that because i edited the source in 32 bit OS ?!
please someone help me to fix that
 
yes
its 64 bit and im using 64 bit server on it right now
but if i edit anything it gives me that error

- - - Updated - - -

its Ubuntu 12.04.2 LTS (GNU/Linux 3.2.0-29-generic x86_64)
 
What do the following commands output:

Code:
which g++
Code:
dpkg -l "*gcc*"
Code:
dpkg -l "*g++*"
Code:
uname -a
Code:
cat /proc/cpuinfo
Code:
gcc -march=native -Q --help=target
Code:
gcc -march=native -E -v - </dev/null 2>&1 | grep cc1
 
Last edited:
which g++

PHP:
/usr/bin/g++


dpkg -l "*gcc*"

PHP:
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name           Version        Description
+++-==============-==============-============================================
ii  gcc            4:4.6.3-1ubunt GNU C compiler
un  gcc-4.1        <none>         (no description available)
un  gcc-4.3        <none>         (no description available)
un  gcc-4.4        <none>         (no description available)
un  gcc-4.4-base   <none>         (no description available)
un  gcc-4.5        <none>         (no description available)
un  gcc-4.5-base   <none>         (no description available)
ii  gcc-4.6        4.6.3-1ubuntu5 GNU C compiler
ii  gcc-4.6-base   4.6.3-1ubuntu5 GCC, the GNU Compiler Collection (base packa
un  gcc-4.6-doc    <none>         (no description available)
un  gcc-4.6-locale <none>         (no description available)
un  gcc-4.6-multil <none>         (no description available)
un  gcc-doc        <none>         (no description available)
un  gcc-multilib   <none>         (no description available)
ii  gccxml         0.9.0+cvs20111 XML output extension to GCC
ii  libgcc1        1:4.6.3-1ubunt GCC support library
un  libgcc1-dbg    <none>         (no description available)

dpkg -l "*g++*"

PHP:
Desired=Unknown/Install/Remove/Purge/Hold
| Status=Not/Inst/Conf-files/Unpacked/halF-conf/Half-inst/trig-aWait/Trig-pend
|/ Err?=(none)/Reinst-required (Status,Err: uppercase=bad)
||/ Name             Version          Description
+++-================-================-================================================
ii  g++              4:4.6.3-1ubuntu5 GNU C++ compiler
ii  g++-4.6          4.6.3-1ubuntu5   GNU C++ compiler
un  g++-4.6-multilib <none>           (no description available)
un  g++-multilib     <none>           (no description available)
un  libg++2.8-dev    <none>           (no description available)
un  libg++27-dev     <none>           (no description available)
un  libg++272-dev    <none>           (no description available)

uname -a

PHP:
Linux 149-210-138-177 3.2.0-29-generic #46-Ubuntu SMP Fri Jul 27 17:03:23 UTC 2012 x86_64 x86_64 x86_64 GNU/Linux

cat /proc/cpuinfo

PHP:
processor       : 0
vendor_id       : GenuineIntel
cpu family      : 6
model           : 2
model name      : QEMU Virtual CPU version 1.3.1
stepping        : 3
microcode       : 0x1
cpu MHz         : 2199.998
cache size      : 4096 KB
fpu             : yes
fpu_exception   : yes
cpuid level     : 4
wp              : yes
flags           : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm rep_good nopl pni cx16 popcnt hypervisor lahf_lm
bogomips        : 4399.99
clflush size    : 64
cache_alignment : 64
address sizes   : 40 bits physical, 48 bits virtual
power management:

processor       : 1
vendor_id       : GenuineIntel
cpu family      : 6
model           : 2
model name      : QEMU Virtual CPU version 1.3.1
stepping        : 3
microcode       : 0x1
cpu MHz         : 2199.998
cache size      : 4096 KB
fpu             : yes
fpu_exception   : yes
cpuid level     : 4
wp              : yes
flags           : fpu de pse tsc msr pae mce cx8 apic sep mtrr pge mca cmov pse36 clflush mmx fxsr sse sse2 syscall nx lm rep_good nopl pni cx16 popcnt hypervisor lahf_lm
bogomips        : 4399.99
clflush size    : 64
cache_alignment : 64
address sizes   : 40 bits physical, 48 bits virtual
power management:


gcc -march=native -Q --help=target

PHP:
The following options are target specific:
  -m128bit-long-double                  [disabled]
  -m32                                  [disabled]
  -m3dnow                               [disabled]
  -m3dnowa                              [disabled]
  -m64                                  [enabled]
  -m80387                               [enabled]
  -m8bit-idiv                           [disabled]
  -m96bit-long-double                   [enabled]
  -mabi=
  -mabm                                 [disabled]
  -maccumulate-outgoing-args            [disabled]
  -maes                                 [disabled]
  -malign-double                        [disabled]
  -malign-functions=
  -malign-jumps=
  -malign-loops=
  -malign-stringops                     [enabled]
  -mandroid                             [disabled]
  -march=                               pentium-m
  -masm=
  -mavx                                 [disabled]
  -mavx256-split-unaligned-load         [disabled]
  -mavx256-split-unaligned-store        [disabled]
  -mbionic                              [disabled]
  -mbmi                                 [enabled]
  -mbranch-cost=
  -mcld                                 [disabled]
  -mcmodel=
  -mcpu=
  -mcrc32                               [disabled]
  -mcx16                                [enabled]
  -mdispatch-scheduler                  [disabled]
  -mf16c                                [disabled]
  -mfancy-math-387                      [enabled]
  -mfentry                              [enabled]
  -mfma                                 [disabled]
  -mfma4                                [disabled]
  -mforce-drap                          [disabled]
  -mfp-ret-in-387                       [enabled]
  -mfpmath=
  -mfsgsbase                            [disabled]
  -mfused-madd
  -mglibc                               [enabled]
  -mhard-float                          [enabled]
  -mieee-fp                             [enabled]
  -mincoming-stack-boundary=
  -minline-all-stringops                [disabled]
  -minline-stringops-dynamically        [disabled]
  -mintel-syntax
  -mlarge-data-threshold=
  -mlwp                                 [disabled]
  -mmmx                                 [disabled]
  -mmovbe                               [disabled]
  -mms-bitfields                        [disabled]
  -mno-align-stringops                  [disabled]
  -mno-fancy-math-387                   [disabled]
  -mno-push-args                        [disabled]
  -mno-red-zone                         [disabled]
  -mno-sse4                             [enabled]
  -momit-leaf-frame-pointer             [disabled]
  -mpc
  -mpclmul                              [disabled]
  -mpopcnt                              [enabled]
  -mprefer-avx128                       [disabled]
  -mpreferred-stack-boundary=
  -mpush-args                           [enabled]
  -mrdrnd                               [disabled]
  -mrecip                               [disabled]
  -mred-zone                            [enabled]
  -mregparm=
  -mrtd                                 [disabled]
  -msahf                                [enabled]
  -msoft-float                          [disabled]
  -msse                                 [disabled]
  -msse2                                [disabled]
  -msse2avx                             [disabled]
  -msse3                                [disabled]
  -msse4                                [disabled]
  -msse4.1                              [disabled]
  -msse4.2                              [disabled]
  -msse4a                               [disabled]
  -msse5
  -msseregparm                          [disabled]
  -mssse3                               [disabled]
  -mstack-arg-probe                     [disabled]
  -mstackrealign                        [enabled]
  -mstringop-strategy=
  -mtbm                                 [disabled]
  -mtls-dialect=
  -mtls-direct-seg-refs                 [enabled]
  -mtune=                               generic
  -muclibc                              [disabled]
  -mveclibabi=
  -mvect8-ret-in-mem                    [disabled]
  -mvzeroupper                          [disabled]
  -mxop                                 [disabled]


gcc -march=native -E -v - </dev/null 2>&1 | grep cc1

PHP:
 /usr/lib/gcc/x86_64-linux-gnu/4.6/cc1 -E -quiet -v -imultilib . -imultiarch x86_64-linux-gnu - -march=pentium-m -mcx16 -msahf -mno-movbe -mno-aes -mno-pclmul -mpopcnt -mno-abm -mno-lwp -mno-fma -mno-fma4 -mno-xop -mbmi -mno-tbm -mno-avx -mno-sse4.2 -mno-sse4.1 --param l1-cache-size=32 --param l1-cache-line-size=64 --param l2-cache-size=4096 -mtune=generic -fstack-protector
 
Is it possible that you use TFS 0.4?
And that you compile it in a virtual machine?

g++ optimizations seem to be problematic in some VMs.
Look in all files for "-march=native" and "-mtune=native" and remove these options.

Then try again.
 
the last error fixed but there is another problem :(

PHP:
g++ -DHAVE_CONFIG_H -I.    -I/usr/include/libxml2  -I/usr/include/lua5.2    -D__USE_MYSQL__  -D__WAR_SYSTEM__ -D__ENABLE_SERVER_DIAGNOSTIC__ -D_THREAD_SAFE -D_REENTRANT -Wall -ggdb -O1 -MT configmanager.o -MD -MP -MF .deps/configmanager.Tpo -c -o configmanager.o configmanager.cpp
configmanager.cpp: In member function 'bool ConfigManager::load()':
configmanager.cpp:41:15: error: 'lua_open' was not declared in this scope
make[1]: *** [configmanager.o] Error 1
make[1]: Leaving directory `/var/project/source-war'
make: *** [all] Error 2
 
already installed and updated

Code:
Reading package lists... Done
Building dependency tree
Reading state information... Done
liblua5.1-0-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 16 not upgraded.
 
installed and upgraded too :(
PHP:
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'liblua5.2-dev' for regex 'liblua5.2'
Note, selecting 'liblua5.2-0-dbg' for regex 'liblua5.2'
Note, selecting 'liblua5.2-0' for regex 'liblua5.2'
liblua5.2-0 is already the newest version.
liblua5.2-0-dbg is already the newest version.
liblua5.2-dev is already the newest version.
0 upgraded, 0 newly installed, 0 to remove and 16 not upgraded.
 
hm, difficult when not having the sources of TFS 0.4.

Looks like LUA 5.2 doesn't even have lua_open anymore.

Try uninstalling LUA 5.2 and run ./configure again.

Code:
apt-get remove liblua5.2-0 liblua5.2-0-dbg liblua5.2-dev
 
Back
Top