Jump to content
  • 0
onunezhe

open Error compiling source. Missing libs/link?

Question

Version of Files : 40250

Hi everyone!

 

I was trying to compile source game (also I must tell that was extremelly hard to find one that at least compile something...), after compiling some libraries it seems to stop on external libs that I don't know why it fails. I am using FreeBSD 11.3-RELEASE-p9

 

After compiling (gmake clean && gmake dep && gmake -j20) returns following error:

/usr/bin/ld: cannot find -lIL
gmake: *** [Makefile:138: ../game_r40250_lycan] Error 1

 

I checked on my Makefile and could be related with graphics, because it happens with all libs on following line:

# DevIL
INCDIR += -I../../libdevil
LIBDIR += -L../../libdevil
LIBS += -lIL -lpng -ltiff -lmng -llcms -ljpeg

I have on that path libdevil dir, but I don't know if there are all files to make it works

http://epvpimg.com/2Mtjbab

 

Furthermore it happens also with another lib. If I comment that line of libs IL, png, etc the error changes to another lib, like mysqlclient. But sincerelly I don't know how to depure this kind of errors and what is missing

/usr/bin/ld: cannot find -lmysqlclient
gmake: *** [Makefile:138: ../game_r40250_lycan] Error 1

 

If do you want to check the full compile output with the line of #DevIL libs check here>

Spoiler

makedepend -f Depend  -I../../../Extern/include/boost -I../../libdevil -I../../libmysql/5.x-5.1.35 -I../../../Extern/include -I../../libhackshield/include -I../../libxtrap/include -I../../liblua/include -I/usr/local/include -I/usr/include/c++/3.3 -I/usr/include/c++/4.2 -pOBJDIR/ BattleArena.cpp FSM.cpp MarkConvert.cpp MarkImage.cpp MarkManager.cpp OXEvent.cpp TrafficProfiler.cpp acce.cpp ani.cpp arena.cpp banword.cpp battle.cpp blend_item.cpp block_country.cpp buffer_manager.cpp building.cpp castle.cpp char.cpp char_affect.cpp char_battle.cpp char_change_empire.cpp char_horse.cpp char_item.cpp char_manager.cpp char_quickslot.cpp char_resist.cpp char_skill.cpp char_state.cpp PetSystem.cpp cmd.cpp cmd_emotion.cpp cmd_general.cpp cmd_gm.cpp cmd_oxevent.cpp config.cpp constants.cpp crc32.cpp cube.cpp db.cpp desc.cpp desc_client.cpp desc_manager.cpp desc_p2p.cpp dev_log.cpp dungeon.cpp empire_text_convert.cpp entity.cpp entity_view.cpp event.cpp event_queue.cpp exchange.cpp file_loader.cpp fishing.cpp gm.cpp guild.cpp guild_manager.cpp guild_war.cpp horse_rider.cpp horsename_manager.cpp input.cpp input_auth.cpp input_db.cpp input_login.cpp input_main.cpp input_p2p.cpp input_teen.cpp input_udp.cpp ip_ban.cpp item.cpp item_addon.cpp item_attribute.cpp item_manager.cpp item_manager_idrange.cpp locale.cpp locale_service.cpp log.cpp login_data.cpp lzo_manager.cpp marriage.cpp matrix_card.cpp messenger_manager.cpp mining.cpp mob_manager.cpp monarch.cpp motion.cpp over9refine.cpp p2p.cpp packet_info.cpp party.cpp passpod.cpp pcbang.cpp polymorph.cpp priv_manager.cpp pvp.cpp questevent.cpp questlua.cpp questlua_affect.cpp questlua_arena.cpp questlua_ba.cpp questlua_building.cpp questlua_danceevent.cpp questlua_dungeon.cpp questlua_forked.cpp questlua_game.cpp questlua_global.cpp questlua_guild.cpp questlua_horse.cpp questlua_pet.cpp questlua_item.cpp questlua_marriage.cpp questlua_mgmt.cpp questlua_monarch.cpp questlua_npc.cpp questlua_oxevent.cpp questlua_party.cpp questlua_pc.cpp questlua_quest.cpp questlua_target.cpp questmanager.cpp questnpc.cpp questpc.cpp refine.cpp regen.cpp safebox.cpp sectree.cpp sectree_manager.cpp sequence.cpp shop.cpp skill.cpp start_position.cpp target.cpp text_file_loader.cpp trigger.cpp utils.cpp vector.cpp war_map.cpp wedding.cpp xmas_event.cpp version.cpp panama.cpp threeway_war.cpp map_location.cpp auth_brazil.cpp BlueDragon.cpp BlueDragon_Binder.cpp DragonLair.cpp questlua_dragonlair.cpp HackShield.cpp HackShield_Impl.cpp char_hackshield.cpp skill_power.cpp affect.cpp SpeedServer.cpp questlua_speedserver.cpp XTrapManager.cpp auction_manager.cpp FileMonitor_FreeBSD.cpp ClientPackageCryptInfo.cpp cipher.cpp buff_on_attributes.cpp dragon_soul_table.cpp DragonSoul.cpp group_text_parse_tree.cpp char_dragonsoul.cpp questlua_dragonsoul.cpp shop_manager.cpp shopEx.cpp item_manager_read_tables.cpp New_PetSystem.cpp questlua_petnew.cpp questlua_mysql.cpp char_cards.cpp offline_shop.cpp offlineshop_manager.cpp offlineshop_config.cpp minilzo.c main.cpp  2> /dev/null > Depend
compile: BattleArena.cpp
compile: FSM.cpp
compile: MarkConvert.cpp
compile: MarkImage.cpp
compile: MarkManager.cpp
compile: OXEvent.cpp
compile: TrafficProfiler.cpp
compile: acce.cpp
compile: ani.cpp
compile: banword.cpp
compile: blend_item.cpp
compile: buffer_manager.cpp
compile: castle.cpp
compile: char_affect.cpp
compile: char_change_empire.cpp
compile: arena.cpp
compile: battle.cpp
compile: block_country.cpp
compile: building.cpp
compile: char_battle.cpp
compile: char.cpp
compile: char_horse.cpp
compile: char_item.cpp
compile: char_manager.cpp
compile: char_quickslot.cpp
compile: char_resist.cpp
compile: char_skill.cpp
compile: char_state.cpp
compile: PetSystem.cpp
compile: cmd.cpp
compile: cmd_emotion.cpp
compile: cmd_general.cpp
compile: cmd_gm.cpp
compile: cmd_oxevent.cpp
compile: config.cpp
compile: crc32.cpp
compile: constants.cpp
compile: cube.cpp
compile: db.cpp
compile: desc.cpp
compile: desc_client.cpp
compile: desc_manager.cpp
compile: desc_p2p.cpp
compile: dev_log.cpp
compile: dungeon.cpp
compile: empire_text_convert.cpp
compile: entity.cpp
compile: entity_view.cpp
compile: event.cpp
compile: event_queue.cpp
compile: exchange.cpp
compile: file_loader.cpp
compile: fishing.cpp
compile: gm.cpp
compile: guild.cpp
compile: guild_manager.cpp
compile: guild_war.cpp
compile: horse_rider.cpp
compile: horsename_manager.cpp
compile: input.cpp
compile: input_db.cpp
compile: input_auth.cpp
compile: input_login.cpp
compile: input_main.cpp
compile: input_p2p.cpp
compile: input_teen.cpp
compile: input_udp.cpp
compile: ip_ban.cpp
compile: item.cpp
compile: item_addon.cpp
compile: item_attribute.cpp
compile: item_manager.cpp
compile: item_manager_idrange.cpp
compile: locale.cpp
compile: locale_service.cpp
compile: log.cpp
compile: login_data.cpp
compile: lzo_manager.cpp
compile: marriage.cpp
compile: matrix_card.cpp
compile: messenger_manager.cpp
compile: mining.cpp
compile: mob_manager.cpp
compile: monarch.cpp
compile: motion.cpp
compile: over9refine.cpp
compile: p2p.cpp
compile: packet_info.cpp
compile: party.cpp
compile: passpod.cpp
compile: pcbang.cpp
compile: polymorph.cpp
compile: priv_manager.cpp
compile: pvp.cpp
compile: questevent.cpp
compile: questlua.cpp
compile: questlua_affect.cpp
compile: questlua_arena.cpp
compile: questlua_building.cpp
compile: questlua_ba.cpp
compile: questlua_danceevent.cpp
compile: questlua_dungeon.cpp
compile: questlua_forked.cpp
compile: questlua_game.cpp
compile: questlua_global.cpp
compile: questlua_guild.cpp
compile: questlua_horse.cpp
compile: questlua_pet.cpp
compile: questlua_item.cpp
compile: questlua_marriage.cpp
compile: questlua_mgmt.cpp
compile: questlua_monarch.cpp
compile: questlua_npc.cpp
compile: questlua_oxevent.cpp
compile: questlua_party.cpp
compile: questlua_pc.cpp
compile: questlua_quest.cpp
compile: questlua_target.cpp
compile: questnpc.cpp
compile: questmanager.cpp
compile: questpc.cpp
compile: refine.cpp
compile: regen.cpp
compile: safebox.cpp
compile: sectree.cpp
compile: sectree_manager.cpp
compile: sequence.cpp
compile: shop.cpp
compile: start_position.cpp
compile: target.cpp
compile: skill.cpp
compile: text_file_loader.cpp
compile: trigger.cpp
compile: utils.cpp
compile: war_map.cpp
compile: vector.cpp
compile: wedding.cpp
compile: xmas_event.cpp
version compile: version.cpp
compile: panama.cpp
compile: threeway_war.cpp
compile: map_location.cpp
compile: auth_brazil.cpp
compile: BlueDragon.cpp
compile: DragonLair.cpp
compile: BlueDragon_Binder.cpp
compile: questlua_dragonlair.cpp
compile: HackShield.cpp
compile: HackShield_Impl.cpp
compile: char_hackshield.cpp
compile: skill_power.cpp
compile: affect.cpp
compile: SpeedServer.cpp
compile: questlua_speedserver.cpp
compile: XTrapManager.cpp
compile: auction_manager.cpp
compile: FileMonitor_FreeBSD.cpp
compile: ClientPackageCryptInfo.cpp
compile: cipher.cpp
compile: buff_on_attributes.cpp
compile: dragon_soul_table.cpp
compile: DragonSoul.cpp
compile: group_text_parse_tree.cpp
compile: char_dragonsoul.cpp
compile: questlua_dragonsoul.cpp
compile: shop_manager.cpp
compile: shopEx.cpp
compile: item_manager_read_tables.cpp
compile: New_PetSystem.cpp
compile: questlua_petnew.cpp
compile: questlua_mysql.cpp
compile: char_cards.cpp
compile: offline_shop.cpp
compile: offlineshop_manager.cpp
compile: offlineshop_config.cpp
minilzo compile: minilzo.c
---- LYCAN SOURCE © PRO SF - 2017 ----
---- GAME SAVED: ../game_r40250_lycan
-------------------------------------------------
/usr/bin/ld: cannot find -lIL
gmake: *** [Makefile:138: ../game_r40250_lycan] Error 1

And if do you want to check the Makefile also check here>

Spoiler

PLATFORM = $(shell file /bin/ls | cut -d' ' -f3 | cut -d'-' -f1)

GCC_VERSION = $(shell $(CC) --version 2>&1 | grep "(GCC)" | cut -d' ' -f3  | cut -d'.' -f1)
BSD_VERSION = $(shell uname -v 2>&1 | cut -d' ' -f2 | cut -d'.' -f1)
SVN_VERSION = 40250
WOLF_ENABLE = lycan

CC = g++

INCDIR =
LIBDIR =
BINDIR = ..
OBJDIR = OBJDIR
$(shell if [ ! -d $(OBJDIR) ]; then mkdir $(OBJDIR); fi)

# Standard Setting
LIBS = -pthread -lm -lmd
# Removed -fno-rtti
CFLAGS = -g -Wall -O2 -m32 -pipe -fexceptions -D_THREAD_SAFE -DNDEBUG -D__SVN_VERSION__=\"$(SVN_VERSION)\"

ifeq ($(GCC_VERSION), 4)
CFLAGS += -mtune=i686 -fstack-protector-all
else
CFLAGS += -mcpu=i686
endif

# boost
INCDIR += -I../../../Extern/include/boost

# DevIL
INCDIR += -I../../libdevil
LIBDIR += -L../../libdevil
LIBS += -lIL -lpng -ltiff -lmng -llcms -ljpeg

# MySQL
ifeq ($(BSD_VERSION), 7)
INCDIR += -I../../libmysql/7.x-5.1.35
LIBDIR += -L../../libmysql/7.x-5.1.35
else
INCDIR += -I../../libmysql/5.x-5.1.35
LIBDIR += -L../../libmysql/5.x-5.1.35
endif

LIBS += -lmysqlclient -lz

# Miscellaneous external libraries
INCDIR += -I../../../Extern/include
LIBDIR += -L../../../Extern/lib
LIBS += -lcryptopp -lgtest

# HackShield
INCDIR += -I../../libhackshield/include
LIBDIR += -L../../libhackshield/lib
LIBS += -lanticpxsvr

# XTrap
INCDIR += -I../../libxtrap/include

# openssl
#INCDIR += -I/usr/include
LIBS += -lssl

# Project Library
INCDIR += -I../../liblua/include
INCDIR += -I/usr/local/include
LIBDIR += -L../../libthecore/lib -L../../libpoly -L../../libsql -L../../libgame/lib -L../../liblua/lib
LIBDIR += -L/usr/local/lib
LIBS += -lthecore -lpoly -llua -llualib -lsql -lgame
USE_STACKTRACE = 0
ifeq ($(USE_STACKTRACE), 1)
LIBS += /usr/local/lib/libexecinfo.a
endif

TARGET  = $(BINDIR)/game_r$(SVN_VERSION)_$(WOLF_ENABLE)

CFILE   = minilzo.c

CPPFILE = BattleArena.cpp FSM.cpp MarkConvert.cpp MarkImage.cpp MarkManager.cpp OXEvent.cpp TrafficProfiler.cpp acce.cpp ani.cpp\
                  arena.cpp banword.cpp battle.cpp blend_item.cpp block_country.cpp buffer_manager.cpp building.cpp castle.cpp\
                  char.cpp char_affect.cpp char_battle.cpp char_change_empire.cpp char_horse.cpp char_item.cpp char_manager.cpp\
                  char_quickslot.cpp char_resist.cpp char_skill.cpp char_state.cpp PetSystem.cpp cmd.cpp cmd_emotion.cpp cmd_general.cpp\
                  cmd_gm.cpp cmd_oxevent.cpp config.cpp constants.cpp crc32.cpp cube.cpp db.cpp desc.cpp\
                  desc_client.cpp desc_manager.cpp desc_p2p.cpp dev_log.cpp dungeon.cpp empire_text_convert.cpp entity.cpp\
                  entity_view.cpp event.cpp event_queue.cpp exchange.cpp file_loader.cpp fishing.cpp gm.cpp guild.cpp\
                  guild_manager.cpp guild_war.cpp horse_rider.cpp horsename_manager.cpp input.cpp input_auth.cpp input_db.cpp\
                  input_login.cpp input_main.cpp input_p2p.cpp input_teen.cpp input_udp.cpp ip_ban.cpp\
                  item.cpp item_addon.cpp item_attribute.cpp item_manager.cpp item_manager_idrange.cpp locale.cpp\
                  locale_service.cpp log.cpp login_data.cpp lzo_manager.cpp marriage.cpp matrix_card.cpp\
                  messenger_manager.cpp mining.cpp mob_manager.cpp monarch.cpp motion.cpp over9refine.cpp p2p.cpp packet_info.cpp\
                  party.cpp passpod.cpp pcbang.cpp polymorph.cpp priv_manager.cpp pvp.cpp\
                  questevent.cpp questlua.cpp questlua_affect.cpp questlua_arena.cpp questlua_ba.cpp questlua_building.cpp\
                  questlua_danceevent.cpp questlua_dungeon.cpp questlua_forked.cpp questlua_game.cpp questlua_global.cpp\
                  questlua_guild.cpp questlua_horse.cpp questlua_pet.cpp questlua_item.cpp questlua_marriage.cpp questlua_mgmt.cpp\
                  questlua_monarch.cpp questlua_npc.cpp questlua_oxevent.cpp questlua_party.cpp questlua_pc.cpp\
                  questlua_quest.cpp questlua_target.cpp questmanager.cpp questnpc.cpp questpc.cpp\
                  refine.cpp regen.cpp safebox.cpp sectree.cpp sectree_manager.cpp sequence.cpp shop.cpp\
                  skill.cpp start_position.cpp target.cpp text_file_loader.cpp trigger.cpp utils.cpp vector.cpp war_map.cpp\
                  wedding.cpp xmas_event.cpp version.cpp panama.cpp threeway_war.cpp map_location.cpp auth_brazil.cpp\
                  BlueDragon.cpp BlueDragon_Binder.cpp DragonLair.cpp questlua_dragonlair.cpp\
                  HackShield.cpp HackShield_Impl.cpp char_hackshield.cpp skill_power.cpp affect.cpp\
                  SpeedServer.cpp questlua_speedserver.cpp XTrapManager.cpp\
                  auction_manager.cpp FileMonitor_FreeBSD.cpp ClientPackageCryptInfo.cpp cipher.cpp\
                  buff_on_attributes.cpp dragon_soul_table.cpp DragonSoul.cpp\
                  group_text_parse_tree.cpp char_dragonsoul.cpp questlua_dragonsoul.cpp\
                  shop_manager.cpp shopEx.cpp item_manager_read_tables.cpp New_PetSystem.cpp questlua_petnew.cpp questlua_mysql.cpp char_cards.cpp offline_shop.cpp offlineshop_manager.cpp offlineshop_config.cpp


COBJS   = $(CFILE:%.c=$(OBJDIR)/%.o)
CPPOBJS = $(CPPFILE:%.cpp=$(OBJDIR)/%.o)

MAINOBJ = $(OBJDIR)/main.o
MAINCPP = main.cpp

### ONLY TEST
#TESTOBJ = $(OBJDIR)/test.o
#TESTCPP = test.cpp
#TEST_TARGET = $(BINDIR)/test

default: $(TARGET)
###default: $(TEST_TARGET)

$(OBJDIR)/minilzo.o: minilzo.c
        @$(CC) -w $(CFLAGS) $(INCDIR) -c $< -o $@
        @echo minilzo compile: $<

$(OBJDIR)/version.o: version.cpp
        @$(CC) -w $(CFLAGS) -D__USER__=\"$(USER)\" -D__HOSTNAME__=\"$(HOSTNAME)\" -D__PWD__=\"$(PWD)\" -D__SVN_VERSION__=\"$(SVN_VERSION)\" -c $< -o $@
        @echo version compile: $<

$(OBJDIR)/%.o: %.cpp
        @echo compile: $<
        @$(CC) -w $(CFLAGS) $(INCDIR) -c $< -o $@

$(TARGET): $(CPPOBJS) $(COBJS) $(MAINOBJ)
        @echo ----     LYCAN SOURCE © PRO SF - 2017     ----
        @echo ----     GAME SAVED: $(TARGET)
        @echo -------------------------------------------------
        @$(CC) -w $(CFLAGS) $(LIBDIR) $(COBJS) $(CPPOBJS) $(MAINOBJ) $(LIBS) -o $(TARGET)
        @touch version.cpp


### ONLY TEST
#$(TEST_TARGET): $(TESTCPP) $(CPPOBJS) $(COBJS) $(TESTOBJ)
#       @echo linking $(TEST_TARGET)
#       @$(CC) -w $(CFLAGS) $(LIBDIR) $(COBJS) $(CPPOBJS) $(TESTOBJ) $(LIBS) -o ../test

clean:
        @rm -f $(COBJS) $(CPPOBJS)
        @rm -f $(BINDIR)/game_r* $(BINDIR)/conv
##      @rm -f $(BINDIR)/test

tag:
        ctags *.cpp *.h *.c

dep:
        makedepend -f Depend $(INCDIR) -I/usr/include/c++/3.3 -I/usr/include/c++/4.2 -p$(OBJDIR)/ $(CPPFILE) $(CFILE) $(MAINCPP) $(TESTCPP) 2> /dev/null > Depend

sinclude Depend

 

 

Thanks in advance!

 

Edited by onunezhe
Missing FreeBSD version (see edit history)

Share this post


Link to post

2 answers to this question

Recommended Posts

  • 0

about the libmysqlclient you need to install mysql56-client package to make it find the library in /usr/lib

the other libs are missing in ur extern, they are easy to find, just using google (search them for freebsd obv)  you should find them and just putting them into your extern/lib folder you should solve all

Share this post


Link to post

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    No registered users viewing this page.

×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.