StarRuler2-Source icon indicating copy to clipboard operation
StarRuler2-Source copied to clipboard

Build error while linking

Open 42triangles opened this issue 6 years ago • 3 comments

The build fails on my Linux system while trying to create bin/lin64/StarRuler2.bin in the linking phase.

The log is below. Errors start appearing in line 826.

starruler2-source-log.txt

Edit: Because there is no preview on github, I'll quickly describe whats going on: A lot of symbols are not found during the linking phase ("[...]: undefined reference to [...]"). This seems to happen to library exports, especially networking and threading.

42triangles avatar Jul 24 '18 23:07 42triangles

The linking line (323) of the linux Makefile is ordered incorrectly. You need to move $(LDFLAGS) to the end. The fixed version is below for clarification of the correct order:

#Complete binary compile
$(BINDIR)/$(BIN): makelibs $(OBJ_FILES) $(LIB_FILES) $(COPY_LIBS)
	@mkdir -p $(BINDIR)
	@$(CC) $(CXXFLAGS) $(OBJ_FILES) $(LIB_FILES) -o $@ $(LDFLAGS)

lucyllewy avatar Jul 25 '18 01:07 lucyllewy

Same here with Debian! Won't link.

Quix0r avatar Jan 25 '22 21:01 Quix0r

@diddledani If you found the fix, can you please fork this project and provide a PR?

Quix0r avatar Jan 25 '22 21:01 Quix0r