summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Makefile3
-rw-r--r--buildlib/environment.mak.in5
-rw-r--r--buildlib/library.mak4
-rw-r--r--cmdline/apt-cache.cc22
-rw-r--r--configure.in8
5 files changed, 35 insertions, 7 deletions
diff --git a/Makefile b/Makefile
index d28fd1350..a2b513423 100644
--- a/Makefile
+++ b/Makefile
@@ -6,7 +6,8 @@
.PHONY: headers library clean veryclean all binary program doc
all headers library clean veryclean binary program doc:
- $(MAKE) -C deity $@
$(MAKE) -C apt-pkg $@
$(MAKE) -C cmdline $@
+ $(MAKE) -C deity $@
+ $(MAKE) -C gui $@
$(MAKE) -C doc $@
diff --git a/buildlib/environment.mak.in b/buildlib/environment.mak.in
index cbc4ca0bb..3166c2e7f 100644
--- a/buildlib/environment.mak.in
+++ b/buildlib/environment.mak.in
@@ -9,8 +9,8 @@ CXXFLAGS+= @CXXFLAGS@ @X_CFLAGS@
# Linker stuff
PICFLAGS+= -fPIC -DPIC
-LFLAGS+= @LDFLAGS@
-XLIBS:=@X_LIBS@ @X_PRE_LIBS@ @X_EXTRA_LIBS@
+LFLAGS+= @LDFLAGS@
+XLIBS:=@X_LIBS@ @X_PRE_LIBS@ @X11LIB@ @X_EXTRA_LIBS@
# Dep generation - this only works for gnu stuff
INLINEDEPFLAG = -MD
@@ -23,3 +23,4 @@ DEBIANDOC_TEXT = @DEBIANDOC_TEXT@
X11LIB = @X11LIB@
GPMLIB = @GPMLIB@
SLANGLIB = @SLANGLIB@
+XPMLIB = @XPMLIB@
diff --git a/buildlib/library.mak b/buildlib/library.mak
index 1b814875f..4ac3760dc 100644
--- a/buildlib/library.mak
+++ b/buildlib/library.mak
@@ -20,6 +20,7 @@ $(LOCAL)-OBJS := $(addprefix $(OBJ)/,$(addsuffix .opic,$(notdir $(basename $(SOU
$(LOCAL)-DEP := $(addprefix $(DEP)/,$(addsuffix .d,$(notdir $(basename $(SOURCE)))))
$(LOCAL)-HEADERS := $(addprefix $(INCLUDE)/,$(HEADERS))
$(LOCAL)-SONAME := lib$(LIBRARY).so.$(MAJOR)
+$(LOCAL)-SLIBS := $(SLIBS)
# Install the command hooks
headers: $($(LOCAL)-HEADERS)
@@ -45,7 +46,8 @@ $(LIB)/lib$(LIBRARY).so: $(LIB)/lib$(LIBRARY).so.$(MAJOR).$(MINOR)
$(LIB)/lib$(LIBRARY).so.$(MAJOR).$(MINOR): $($(LOCAL)-HEADERS) $($(LOCAL)-OBJS)
echo Building shared library $@
$(CXX) $(CXXFLAGS) $(LDFLAGS) $(PICFLAGS) $(LFLAGS) -o $@ \
- -Wl,-soname -Wl,$($(@F)-SONAME) -shared $(filter %.opic,$^)
+ -Wl,-soname -Wl,$($(@F)-SONAME) -shared $(filter %.opic,$^) \
+ $($(@F)-SLIBS)
# Compilation rules
vpath %.cc $(SUBDIRS)
diff --git a/cmdline/apt-cache.cc b/cmdline/apt-cache.cc
index 97211a57a..4d0a076a8 100644
--- a/cmdline/apt-cache.cc
+++ b/cmdline/apt-cache.cc
@@ -1,6 +1,6 @@
// -*- mode: cpp; mode: fold -*-
// Description /*{{{*/
-// $Id: apt-cache.cc,v 1.5 1998/07/21 05:33:21 jgg Exp $
+// $Id: apt-cache.cc,v 1.6 1998/07/26 23:11:56 jgg Exp $
/* ######################################################################
apt-cache - Manages the cache file.
@@ -29,6 +29,7 @@
#include <apt-pkg/deblistparser.h>
#include <apt-pkg/init.h>
#include <apt-pkg/progress.h>
+#include <apt-pkg/sourcelist.h>
#include <iostream.h>
#include <fstream.h>
@@ -299,6 +300,17 @@ bool DoAdd(int argc,char *argv[])
return true;
}
/*}}}*/
+// GenCaches - Call the main cache generator /*{{{*/
+// ---------------------------------------------------------------------
+/* */
+bool GenCaches()
+{
+ OpTextProgress Progress;
+ pkgSourceList List;
+ List.ReadMainList();
+ return pkgMakeStatusCache(List,Progress);
+}
+ /*}}}*/
int main(int argc, char *argv[])
{
@@ -319,6 +331,12 @@ int main(int argc, char *argv[])
break;
}
+ if (strcmp(argv[1],"gencaches") == 0)
+ {
+ GenCaches();
+ break;
+ }
+
// Open the cache file
FileFd CacheF(CacheFile,FileFd::ReadOnly);
if (_error->PendingError() == true)
@@ -356,7 +374,7 @@ int main(int argc, char *argv[])
DumpAvail(Cache);
break;
}
-
+
_error->Error("Invalid operation %s", argv[1]);
break;
}
diff --git a/configure.in b/configure.in
index 61460e290..a5be451b8 100644
--- a/configure.in
+++ b/configure.in
@@ -33,8 +33,14 @@ AC_PATH_XTRA
AC_SUBST(X11LIB)
X11LIB=
if test "$no_x" != "yes"; then
- X11LIB="-lx11"
+ X11LIB="-lX11"
AC_DEFINE(HAVE_X11)
+ dnl Checks for Slang
+ AC_CHECK_LIB(Xpm, XpmLibraryVersion,[AC_DEFINE(HAVE_LIBXPM) XPMLIB="-lXpm"],,$X_LIBS $X_PRE_LIBS $X11LIB $X_EXTRA_LIBS)
+ AC_SUBST(XPMLIB)
+ if test "$XPMLIB" != "-lXpm"; then
+ AC_MSG_ERROR(failed: I need xpm if you are building for X)
+ fi
fi
dnl Checks for Slang