#include #include /* ** The standard distribution includes a copy of the TIFF library (libtiff) ** in libIV.a. As this duplicates libtiff and as you might get surprises ** if you install a new version of libtiff.a and nothing changes (due to ** ld ... -lIV -ltiff ...), I have removed libtiff.a from libIV.a. ** libtiff.a is available for Linux (as normal and shared library) as part ** of the libgr package. For those who want to include the TIFF library ** in libIV.so, they can do so by changing the HasLibTIFF to NO. */ /* NOTE: This can't be redefined in local.def (used here already) */ #undef HasLibTIFF #define HasLibTIFF YES #define HasLinuxSharedLibraries YES #undef SharedCCFlags #define SharedCCFlags -B/usr/dll/jump/ /* ** The rest of this file redefines macros from rules.def (mostly). ** The shared library stuff hasn't been done really generic in rules.def. ** Many def's depend on HasSunOSSharedLibraries. These should really be ** in iv-sun.cf which would look like this file, then. */ #if HasLibTIFF #undef Ld_libIV #define Ld_libIV LdPath(IV) -ltiff #else #undef TIFFCDriver #define TIFFCDriver env JUMP_LIB=$(JUMP_LIB) JUMP_DIR=$(JUMP_DIR) CcCmd #endif #if defined(UseNonShared) && defined(InObjectCodeDir) #define NonSharedCCLdFlags -static #else #define NonSharedCCLdFlags /**/ #endif /* Don't use (i.e., refer to explicitly) shlibs under certain circumstances */ #if defined(UseNonShared) && defined(InObjectCodeDir) || defined(UseInstalled) #undef HasLinuxSharedLibraries #define HasLinuxSharedLibraries NO /* don't use them anyway */ #endif #if HasLinuxSharedLibraries || defined(UseInstalled) #define DepPath(name) /* as nothing */ #else #define DepPath(name) Concat($(LIBSRC)/name/$(ARCH)/lib,name.a) #endif #define MakeWorld(flags) @@\ MakeNormalWorld(flags) @@\ MakeSpecialWorld(.debug,flags) @@\ MakeSpecialWorld(.noshared,flags) #define MakeInSubdirs(dirs) @@\ MakefilesSubdirs(dirs) @@\ DependSubdirs(dirs) @@\ MakeSubdirs(dirs) @@\ InstallSubdirs(dirs) @@\ CleanSubdirs(dirs) @@\ SpecialTargets(debug,-DUseDebug) @@\ SpecialTargets(noshared,-DUseNonShared) #define MakeInObjectCodeDir() @@\ MakefileObjectCodeDir($(ARCH)) @@\ DependSubdirs($(ARCH)) @@\ MakeSubdirs($(ARCH)) @@\ InstallSubdirs($(ARCH)) @@\ CleanSubdirs($(ARCH)) @@\ SpecialTargets(debug,-DUseDebug) @@\ SpecialTargets(noshared,-DUseNonShared) #define NormalLinuxSharedLibraryTarget(libname,rev,depobjs,ldobjs) @@\ REV = rev.2 @@\ AOUT = Concat(lib,libname.so.$(REV)) @@\ CCDRIVER = env JUMP_LIB=$(JUMP_LIB) JUMP_DIR=$(JUMP_DIR) CCDriver @@\ SHARED_CCFLAGS = SharedCCFlags @@\ @@\ AllTarget(Concat(lib,libname.so.$(REV)) Concat(lib,libname.sa)) @@\ @@\ Concat(lib,libname.so.$(REV)) Concat(lib,libname.sa): depobjs @@\ @echo "building lib$(LIB)" @@\ $(RM) Concat(lib,libname.so.$(REV)) Concat(lib,libname.sa) @@\ env JUMP_LIB=$(JUMP_LIB) JUMP_DIR=$(JUMP_DIR) \ @@\ $(DLL_BINDIR)/mkimage \ @@\ -l Concat(lib,libname) -v $(REV) $(JUMP_PARAM) \ @@\ -- -L$(GCCLIBPATH) $(OBJS) $(CCLDLIBS) -lgcc -lc -lgcc @@\ env JUMP_LIB=$(JUMP_LIB) JUMP_DIR=$(JUMP_DIR) \ @@\ $(DLL_BINDIR)/mkstubs \ @@\ -l Concat(lib,libname) -v $(REV) $(JUMP_PARAM) \ @@\ -- Concat(lib,libname) @@\ @@\ clean:: @@\ $(RM) Concat(lib,libname.so.$(REV)) #define InstallLinuxSharedLibrary(libname,rev,dest) @@\ install:: Concat(lib,libname.so.$(REV)) Concat(lib,libname.sa) @@\ MakeDir(dest) @@\ $(INSTALL) -c $(INSTPGMFLAGS) \ @@\ Concat(lib,libname.so.$(REV)) dest @@\ $(INSTALL) -c $(INSTLIBFLAGS) \ @@\ Concat(lib,libname.sa) dest @@\ $(RANLIB) $(RANLIBINSTFLAGS) dest/Concat(lib,libname.sa) #if HasLinuxSharedLibraries #define NormalLibraryTarget(libname,rev,depobjs,ldobjs) @@\ NormalLinuxSharedLibraryTarget(libname,rev,depobjs,ldobjs) #else #define NormalLibraryTarget(libname,rev,depobjs,ldobjs) @@\ NormalNonSharedLibraryTarget(libname,depobjs,ldobjs) #endif #if HasLinuxSharedLibraries #define InstallLibrary(libname,rev,dest) @@\ InstallLinuxSharedLibrary(libname,rev,dest) #else #define InstallLibrary(libname,rev,dest) @@\ InstallNonSharedLibrary(libname,dest) #endif