From e993e7256a453fd312c9c247ad1dab6d7655f34e Mon Sep 17 00:00:00 2001 From: Christian Stimming Date: Thu, 9 Mar 2006 14:28:54 +0000 Subject: [PATCH] Replace "ln -sf" by "$(LN_S) -f" for systems that don't have symbolic links available. git-svn-id: svn+ssh://svn.gnucash.org/repo/gnucash/trunk@13556 57a11ea4-9604-0410-9ed3-97b8803252fd --- ChangeLog | 3 +++ Makefile.am | 4 ++-- configure.in | 2 +- lib/guile-www/Makefile.am | 4 ++-- src/app-utils/Makefile.am | 6 +++--- src/business/business-core/Makefile.am | 6 +++--- src/business/business-gnome/Makefile.am | 6 +++--- src/business/business-reports/Makefile.am | 6 +++--- src/business/business-utils/Makefile.am | 4 ++-- src/business/dialog-tax-table/Makefile.am | 6 +++--- src/core-utils/Makefile.am | 6 +++--- src/engine/Makefile.am | 6 +++--- src/gnc-module/Makefile.am | 6 +++--- src/gnome-utils/Makefile.am | 8 ++++---- src/gnome/Makefile.am | 6 +++--- src/import-export/Makefile.am | 10 +++++----- src/import-export/qif-import/Makefile.am | 10 +++++----- src/import-export/qif-io-core/Makefile.am | 6 +++--- src/optional/swig/Makefile.am | 4 ++-- src/register/register-core/Makefile.am | 8 ++++---- src/report/locale-specific/us/Makefile.am | 10 +++++----- src/report/report-gnome/Makefile.am | 8 ++++---- src/report/report-system/Makefile.am | 8 ++++---- src/report/standard-reports/Makefile.am | 6 +++--- src/report/stylesheets/Makefile.am | 6 +++--- src/report/utility-reports/Makefile.am | 6 +++--- src/scm/Makefile.am | 4 ++-- src/scm/gnumeric/Makefile.am | 2 +- src/scm/printing/Makefile.am | 2 +- src/tax/us/Makefile.am | 6 +++--- 30 files changed, 89 insertions(+), 86 deletions(-) diff --git a/ChangeLog b/ChangeLog index 7463167b3c..286bef58de 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,5 +1,8 @@ 2006-03-09 Christian Stimming + * configure.in, Makefile.am: Replace "ln -sf" by "$(LN_S) -f" for + systems that don't have symbolic links available. + * configure.in, src/gnome-utils/gnc-druid-provider-file-gnome.h: Check for and provide own typedef if header unavailable. diff --git a/Makefile.am b/Makefile.am index efa10fbbfa..f069ae992b 100644 --- a/Makefile.am +++ b/Makefile.am @@ -102,10 +102,10 @@ make-gnucash-potfiles: make-gnucash-potfiles.in Makefile .links: rm -f goffice gsf if !HAVE_GOFFICE - ln -sf . goffice + $(LN_S) -f . goffice endif if !HAVE_LIBGSF - ln -sf $(srcdir)/lib/libgsf-1.12.3/gsf gsf + $(LN_S) -f $(srcdir)/lib/libgsf-1.12.3/gsf gsf endif touch .links diff --git a/configure.in b/configure.in index 469af7d74a..fef80a4461 100644 --- a/configure.in +++ b/configure.in @@ -89,6 +89,7 @@ AC_SUBST(LIBTOOL_DEPS) AC_ISC_POSIX AC_C_BIGENDIAN AC_PROG_MAKE_SET +AC_PROG_LN_S AC_HEADER_STDC AC_CHECK_HEADERS(limits.h sys/times.h) @@ -1514,7 +1515,6 @@ then AC_ISC_POSIX AC_PROG_YACC AM_PROG_LEX - AC_PROG_LN_S AM_PROG_LIBTOOL AC_STDC_HEADERS AC_SYS_LARGEFILE diff --git a/lib/guile-www/Makefile.am b/lib/guile-www/Makefile.am index f0b78ba1ae..f170a14f2b 100644 --- a/lib/guile-www/Makefile.am +++ b/lib/guile-www/Makefile.am @@ -16,10 +16,10 @@ endif .scm-links: rm -f www - ln -sf . www + $(LN_S) -f . www if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/app-utils/Makefile.am b/src/app-utils/Makefile.am index 3dce6bfd60..83b9a3ce89 100644 --- a/src/app-utils/Makefile.am +++ b/src/app-utils/Makefile.am @@ -114,11 +114,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/business/business-core/Makefile.am b/src/business/business-core/Makefile.am index 5bafd4f368..6cf18bbf52 100644 --- a/src/business/business-core/Makefile.am +++ b/src/business/business-core/Makefile.am @@ -90,11 +90,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/business/business-gnome/Makefile.am b/src/business/business-gnome/Makefile.am index 8c60b8467a..ccc82f8ca1 100644 --- a/src/business/business-gnome/Makefile.am +++ b/src/business/business-gnome/Makefile.am @@ -112,11 +112,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/business/business-reports/Makefile.am b/src/business/business-reports/Makefile.am index e3872ce8b1..1de5284454 100644 --- a/src/business/business-reports/Makefile.am +++ b/src/business/business-reports/Makefile.am @@ -15,11 +15,11 @@ endif .scm-links: rm -f gnucash report - ln -sf . gnucash - ln -sf ${srcdir} report + $(LN_S) -f . gnucash + $(LN_S) -f ${srcdir} report if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/business/business-utils/Makefile.am b/src/business/business-utils/Makefile.am index 5d89b5d573..ee02785261 100644 --- a/src/business/business-utils/Makefile.am +++ b/src/business/business-utils/Makefile.am @@ -48,10 +48,10 @@ endif .scm-links: rm -f gnucash - ln -sf ${srcdir} gnucash + $(LN_S) -f ${srcdir} gnucash if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/business/dialog-tax-table/Makefile.am b/src/business/dialog-tax-table/Makefile.am index ae3f36dd94..ae8a0628c7 100644 --- a/src/business/dialog-tax-table/Makefile.am +++ b/src/business/dialog-tax-table/Makefile.am @@ -69,11 +69,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/core-utils/Makefile.am b/src/core-utils/Makefile.am index 7ac831e010..352fe26aba 100644 --- a/src/core-utils/Makefile.am +++ b/src/core-utils/Makefile.am @@ -50,11 +50,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/engine/Makefile.am b/src/engine/Makefile.am index 1f851b7c8a..ef7861b296 100644 --- a/src/engine/Makefile.am +++ b/src/engine/Makefile.am @@ -163,11 +163,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/gnc-module/Makefile.am b/src/gnc-module/Makefile.am index d9b0efd88b..1a87c0eca4 100644 --- a/src/gnc-module/Makefile.am +++ b/src/gnc-module/Makefile.am @@ -54,11 +54,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/gnome-utils/Makefile.am b/src/gnome-utils/Makefile.am index 24246002e3..585e3387d0 100644 --- a/src/gnome-utils/Makefile.am +++ b/src/gnome-utils/Makefile.am @@ -289,11 +289,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links @@ -318,7 +318,7 @@ DISTCLEANFILES = ${SCM_FILE_LINKS} gw-gnome-utils.html # them in ${pkgdatadir}/gnome/help/${program}. # install-data-hook: - ln -sf ../gnome ${DESTDIR}/${pkgdatadir} + $(LN_S) -f ../gnome ${DESTDIR}/${pkgdatadir} uninstall-hook: rm -f ${DESTDIR}/${pkgdatadir}/gnome diff --git a/src/gnome/Makefile.am b/src/gnome/Makefile.am index 5d2072fb3e..1360f8461e 100644 --- a/src/gnome/Makefile.am +++ b/src/gnome/Makefile.am @@ -175,11 +175,11 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/import-export/Makefile.am b/src/import-export/Makefile.am index 2be30a2afa..9e36a7a688 100644 --- a/src/import-export/Makefile.am +++ b/src/import-export/Makefile.am @@ -84,13 +84,13 @@ noinst_DATA = .scm-links .scm-links: rm -f g-wrapped gnucash generic-import import-export - ln -sf . import-export - ln -sf . gnucash - ln -sf . generic-import - ln -sf . g-wrapped + $(LN_S) -f . import-export + $(LN_S) -f . gnucash + $(LN_S) -f . generic-import + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/import-export/qif-import/Makefile.am b/src/import-export/qif-import/Makefile.am index 82ce64c215..50ab71ecd4 100644 --- a/src/import-export/qif-import/Makefile.am +++ b/src/import-export/qif-import/Makefile.am @@ -87,13 +87,13 @@ noinst_DATA = .scm-links .scm-links: rm -f g-wrapped gnucash import-export qif-import - ln -sf . qif-import # to fix (load "qif-import/foo.scm") - ln -sf . import-export - ln -sf . gnucash - ln -sf . g-wrapped + $(LN_S) -f . qif-import # to fix (load "qif-import/foo.scm") + $(LN_S) -f . import-export + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/import-export/qif-io-core/Makefile.am b/src/import-export/qif-io-core/Makefile.am index d79ed6c6b2..486cda24f4 100644 --- a/src/import-export/qif-io-core/Makefile.am +++ b/src/import-export/qif-io-core/Makefile.am @@ -26,11 +26,11 @@ endif .scm-links: rm -f gnucash import-export - ln -sf . gnucash - ln -sf . import-export + $(LN_S) -f . gnucash + $(LN_S) -f . import-export if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/optional/swig/Makefile.am b/src/optional/swig/Makefile.am index e2885f7b1a..f4e161a34b 100644 --- a/src/optional/swig/Makefile.am +++ b/src/optional/swig/Makefile.am @@ -67,10 +67,10 @@ SWIG_INPUT_HDRS := \ install-data-local: libgncswig.la cd ${DESTDIR}${perllibdir} && rm -f gnucash.so if [ -f ${DESTDIR}${perllibdir}/libgncswig.so ]; then \ - cd ${DESTDIR}${perllibdir} && ln -s libgncswig.so gnucash.so; \ + cd ${DESTDIR}${perllibdir} && $(LN_S) -f libgncswig.so gnucash.so; \ elif [ -f ${DESTDIR}${perllibdir}/libgncswig.so.0 ]; then \ cd ${DESTDIR}${perllibdir} && \ - ln -s libgncswig.so.0 gnucash.so; \ + $(LN_S) -f libgncswig.so.0 gnucash.so; \ else \ echo "Can't find libgncswig shared library!" \ exit 1; \ diff --git a/src/register/register-core/Makefile.am b/src/register/register-core/Makefile.am index 36df93ab27..20050be10c 100644 --- a/src/register/register-core/Makefile.am +++ b/src/register/register-core/Makefile.am @@ -81,12 +81,12 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped - ln -sf . register + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped + $(LN_S) -f . register if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/locale-specific/us/Makefile.am b/src/report/locale-specific/us/Makefile.am index 414585f221..a787fd1461 100644 --- a/src/report/locale-specific/us/Makefile.am +++ b/src/report/locale-specific/us/Makefile.am @@ -32,13 +32,13 @@ endif .scm-links: rm -f gnucash report locale-specific us - ln -sf . gnucash - ln -sf . report - ln -sf ${srcdir} locale-specific - ln -sf . us + $(LN_S) -f . gnucash + $(LN_S) -f . report + $(LN_S) -f ${srcdir} locale-specific + $(LN_S) -f . us if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/report-gnome/Makefile.am b/src/report/report-gnome/Makefile.am index bf592d5bae..9814d9b019 100644 --- a/src/report/report-gnome/Makefile.am +++ b/src/report/report-gnome/Makefile.am @@ -88,12 +88,12 @@ endif .scm-links: rm -f gnucash g-wrapped - ln -sf . gnucash - ln -sf . g-wrapped - ln -sf ${srcdir} report + $(LN_S) -f . gnucash + $(LN_S) -f . g-wrapped + $(LN_S) -f ${srcdir} report if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/report-system/Makefile.am b/src/report/report-system/Makefile.am index 1daaa34186..a4cac9ff14 100644 --- a/src/report/report-system/Makefile.am +++ b/src/report/report-system/Makefile.am @@ -58,12 +58,12 @@ endif .scm-links: rm -f gnucash report g-wrapped - ln -sf . gnucash - ln -sf . report - ln -sf . g-wrapped + $(LN_S) -f . gnucash + $(LN_S) -f . report + $(LN_S) -f . g-wrapped if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/standard-reports/Makefile.am b/src/report/standard-reports/Makefile.am index 8c9a4b257f..e3e5422fa1 100644 --- a/src/report/standard-reports/Makefile.am +++ b/src/report/standard-reports/Makefile.am @@ -40,11 +40,11 @@ endif .scm-links: rm -f gnucash report - ln -sf . gnucash - ln -sf ${srcdir} report + $(LN_S) -f . gnucash + $(LN_S) -f ${srcdir} report if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/stylesheets/Makefile.am b/src/report/stylesheets/Makefile.am index e1ee155c9b..f5bf6465e0 100644 --- a/src/report/stylesheets/Makefile.am +++ b/src/report/stylesheets/Makefile.am @@ -41,11 +41,11 @@ endif .scm-links: rm -f gnucash report - ln -sf . gnucash - ln -sf ${srcdir} report + $(LN_S) -f . gnucash + $(LN_S) -f ${srcdir} report if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/report/utility-reports/Makefile.am b/src/report/utility-reports/Makefile.am index eb51d882be..4cc26880e7 100644 --- a/src/report/utility-reports/Makefile.am +++ b/src/report/utility-reports/Makefile.am @@ -28,11 +28,11 @@ endif .scm-links: rm -f gnucash report - ln -sf . gnucash - ln -sf ${srcdir} report + $(LN_S) -f . gnucash + $(LN_S) -f ${srcdir} report if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/scm/Makefile.am b/src/scm/Makefile.am index 2cad2b5993..faff6334aa 100644 --- a/src/scm/Makefile.am +++ b/src/scm/Makefile.am @@ -32,10 +32,10 @@ endif .scm-links: rm -f gnucash - ln -sf ${srcdir} gnucash + $(LN_S) -f ${srcdir} gnucash if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/scm/gnumeric/Makefile.am b/src/scm/gnumeric/Makefile.am index 8a1f3d14de..7ef9fc6c3d 100644 --- a/src/scm/gnumeric/Makefile.am +++ b/src/scm/gnumeric/Makefile.am @@ -11,7 +11,7 @@ endif .scm-links: if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/scm/printing/Makefile.am b/src/scm/printing/Makefile.am index bfd28f7fef..2f1677f7ca 100644 --- a/src/scm/printing/Makefile.am +++ b/src/scm/printing/Makefile.am @@ -13,7 +13,7 @@ endif .scm-links: if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links diff --git a/src/tax/us/Makefile.am b/src/tax/us/Makefile.am index a81fd203ab..85a12fc809 100644 --- a/src/tax/us/Makefile.am +++ b/src/tax/us/Makefile.am @@ -29,11 +29,11 @@ endif .scm-links: rm -f gnucash tax - ln -sf . gnucash - ln -sf . tax + $(LN_S) -f . gnucash + $(LN_S) -f . tax if GNUCASH_SEPARATE_BUILDDIR for X in ${SCM_FILE_LINKS} ; do \ - ln -sf ${srcdir}/$$X . ; \ + $(LN_S) -f ${srcdir}/$$X . ; \ done endif touch .scm-links