{"thread":{"id":"43366","subject":"Re: [PATCH 2/3] Include -lz when linking git-daemon.","startedAt":"2006-11-05T05:36:15Z","lastAt":"2006-11-05T07:28:25Z","messageCount":3,"participants":["Junio C Hamano","Shawn O. Pearce"],"isPatch":true,"patchVersion":1,"patchTotal":3},"messages":[{"id":"294777","messageId":"20061105053615.GB4193@spearce.org","threadId":"43366","inReplyTo":null,"subject":"[PATCH 2/3] Include -lz when linking git-daemon.","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2006-11-05T05:36:15Z","receivedAt":"2006-11-05T05:36:15Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Some platforms (Solaris in particular) appear to require -lz as\npart of the link line for git-daemon, due to it linking against\nsha1_file.o and that module requiring inflate/deflate support.\n\nThis wasn't made platform-specific in the Makefile as the existing\nuse of -lz in every other (non git-daemon) application is also\nnot platform-specific.\n\nSigned-off-by: Shawn O. Pearce <spearce@spearce.org>\n---\n Makefile |    1 +\n 1 files changed, 1 insertions(+), 0 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 1cc9f58..9f10054 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -317,6 +317,7 @@ BUILTIN_OBJS = \\\n \n GITLIBS = $(LIB_FILE) $(XDIFF_LIB)\n EXTLIBS = -lz\n+SIMPLE_LIB = -lz\n \n #\n # Platform specific tweaks\n-- \n1.4.3.3.g9621\n"},{"id":"294511","messageId":"7vveluuzzi.fsf@assigned-by-dhcp.cox.net","threadId":"43366","inReplyTo":"20061105053615.GB4193@spearce.org","subject":"Re: [PATCH 2/3] Include -lz when linking git-daemon.","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2006-11-05T07:14:25Z","receivedAt":"2006-11-05T07:14:25Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Shawn O. Pearce\" <spearce@spearce.org> writes:\n\n> Some platforms (Solaris in particular) appear to require -lz as\n> part of the link line for git-daemon, due to it linking against\n> sha1_file.o and that module requiring inflate/deflate support.\n\nWe once tried to stay away from linking sha1_file into daemon,\nbut it appears we were not successful.\n\nHonestly speaking, I think SIMPLE_PROGRAMS outlived its\nusefulness.  How about moving git-daemon to PROGRAMS list and\nget rid of SIMPLE_ stuff from the Makefile?\n"},{"id":"294612","messageId":"20061105072825.GB4579@spearce.org","threadId":"43366","inReplyTo":"7vveluuzzi.fsf@assigned-by-dhcp.cox.net","subject":"[PATCH 2/2] Remove SIMPLE_PROGRAMS and make git-daemon a normal program.","fromName":"Shawn O. Pearce","fromEmail":"spearce@spearce.org","sentAt":"2006-11-05T07:28:25Z","receivedAt":"2006-11-05T07:28:25Z","isPatch":true,"sender":{"key":"spearce@spearce.org","avatar":"https://avatars.githubusercontent.com/u/34844?v=4"},"body":"Some platforms (Solaris in particular) appear to require -lz as\npart of the link line for git-daemon, due to it linking against\nsha1_file.o and that module requiring inflate/deflate support.\n\nSo its time to retire SIMPLE_PROGRAMS and move its last remaining\nmember into the standard PROGRAMS list, allowing it to link against\nall libraries used by the rest of Git.\n\nSigned-off-by: Shawn O. Pearce <spearce@spearce.org>\n---\n My earlier git-daemon -lz fix, but rewritten to address\n Junio's suggestion of just removing SIMPLE_PROGRAMS...\n\n Makefile |   14 ++------------\n 1 files changed, 2 insertions(+), 12 deletions(-)\n\ndiff --git a/Makefile b/Makefile\nindex 1cc9f58..7c3860a 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -187,15 +187,12 @@ SCRIPTS = $(patsubst %.sh,%,$(SCRIPT_SH)\n \t  $(patsubst %.py,%,$(SCRIPT_PYTHON)) \\\n \t  git-cherry-pick git-status git-instaweb\n \n-# The ones that do not have to link with lcrypto, lz nor xdiff.\n-SIMPLE_PROGRAMS = \\\n-\tgit-daemon$X\n-\n # ... and all the rest that could be moved out of bindir to gitexecdir\n PROGRAMS = \\\n \tgit-convert-objects$X git-fetch-pack$X git-fsck-objects$X \\\n \tgit-hash-object$X git-index-pack$X git-local-fetch$X \\\n \tgit-merge-base$X \\\n+\tgit-daemon$X \\\n \tgit-merge-index$X git-mktag$X git-mktree$X git-patch-id$X \\\n \tgit-peek-remote$X git-receive-pack$X \\\n \tgit-send-pack$X git-shell$X \\\n@@ -217,7 +214,7 @@ BUILT_INS = \\\n \t$(patsubst builtin-%.o,git-%$X,$(BUILTIN_OBJS))\n \n # what 'all' will build and 'install' will install, in gitexecdir\n-ALL_PROGRAMS = $(PROGRAMS) $(SIMPLE_PROGRAMS) $(SCRIPTS) \\\n+ALL_PROGRAMS = $(PROGRAMS) $(SCRIPTS) \\\n \tgit-merge-recur$X\n \n # Backward compatibility -- to be removed after 1.0\n@@ -486,11 +483,9 @@ ifdef NEEDS_LIBICONV\n endif\n ifdef NEEDS_SOCKET\n \tEXTLIBS += -lsocket\n-\tSIMPLE_LIB += -lsocket\n endif\n ifdef NEEDS_NSL\n \tEXTLIBS += -lnsl\n-\tSIMPLE_LIB += -lnsl\n endif\n ifdef NO_D_TYPE_IN_DIRENT\n \tBASIC_CFLAGS += -DNO_D_TYPE_IN_DIRENT\n@@ -737,11 +732,6 @@ endif\n git-%$X: %.o $(GITLIBS)\n \t$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) $(LIBS)\n \n-$(SIMPLE_PROGRAMS) : $(LIB_FILE)\n-$(SIMPLE_PROGRAMS) : git-%$X : %.o\n-\t$(CC) $(ALL_CFLAGS) -o $@ $(ALL_LDFLAGS) $(filter %.o,$^) \\\n-\t\t$(LIB_FILE) $(SIMPLE_LIB)\n-\n ssh-pull.o: ssh-fetch.c\n ssh-push.o: ssh-upload.c\n git-local-fetch$X: fetch.o\n-- \n"}]}