Changeset ee668e in git


Ignore:
Timestamp:
Nov 17, 2011, 5:23:11 PM (12 years ago)
Author:
Jan Engelhardt <jengelh@…>
Branches:
(u'spielwiese', '5b153614cbc72bfa198d75b1e9e33dab2645d9fe')
Children:
b7d64b3fc45a85f34ae6f34e9c227eed2796c70f
Parents:
f0168a594d5a00a74dd169a3d0189411e29989f4
git-author:
Jan Engelhardt <jengelh@medozas.de>2011-11-17 17:23:11+01:00
git-committer:
Oleksandr Motsak <motsak@mathematik.uni-kl.de>2012-01-06 21:09:33+01:00
Message:
factory/build: restore out-of-tree build support

When attempting an OOT build, it fails to find <factory/cplusplus.h>,
because cplusplus.h is always (even in in-tree builds) produced in
"${builddir}", and not "${top_srcdir}/../factory".

Furthermore, one must not rely on the basename of ${top_srcdir}, and
going above ${top_srcdir} is undefined and may lead to spurious build
failures. (Consider a hypothetical chroot on ${top_srcdir}).

Therefore, create a directory include/factory and use -Iinclude such
that <factory/*> yields a buildable state, move all exported header
files there.

Previous OOT build log:

17:22 seven:../factory/obj > make
  CXX    cplusplus.o
  CXXLD  cplusplus
./cplusplus > ./cplusplus.h
../bin/makeheader ../factory.template factory.h
../bin/makeheader ../factoryconf.template factoryconf.h
  YACC   readcf.cc
make  all-am
make[1]: Entering directory `/home/jengelh/obs/zu/home/jengelh/science/singsource/factory/obj'
  CXX    libfactory_a-algext.o
  CXX    libfactory_a-canonicalform.o
In file included from ../cf_factory.h:12:0,
                 from ../canonicalform.cc:7:
../../factory/cf_gmp.h:14:33: fatal error: factory/cplusplus.h: Ingen slik fil eller filkatalog
compilation terminated.
make[1]: *** [libfactory_a-canonicalform.o] Error 1
make[1]: Leaving directory `/home/jengelh/obs/zu/home/jengelh/science/singsource/factory/obj'
make: *** [all] Error 2
Location:
factory
Files:
2 added
22 edited
5 moved

Legend:

Unmodified
Added
Removed
  • factory/.gitignore

    rf0168a5 ree668e  
    1 cplusplus
    2 cplusplus.h
    3 test-g
    4 test-r
     1/cplusplus
     2/cplusplus.h
     3/test-g
     4/test-r
  • factory/Makefile.am

    rf0168a5 ree668e  
    11ACLOCAL_AMFLAGS = -I ../m4
    22
     3SUBDIRS = include/factory
     4
    35CXXTEMPLFLAGS      =  --no-exceptions ## -fno-implicit-templates
    46
    5 AM_CPPFLAGS = -I${top_srcdir} -I${top_srcdir}/.. -I${top_builddir} -I${top_builddir}/.. -I${srcdir} ${GMP_CFLAGS} ${NTL_CFLAGS}
     7AM_CPPFLAGS = -Iinclude -I${srcdir}/include ${GMP_CFLAGS} ${NTL_CFLAGS}
    68
    79lib_LTLIBRARIES = libfactory.la libfactory_g.la
     
    108110nodist_libfactory_g_la_SOURCES = cplusplus.h factory.h factoryconf.h
    109111
    110 
    111112# factory header files
    112113factory_headers = \
     
    182183noinst_HEADERS = $(factory_headers)
    183184
    184 libfactory_includedir=$(includedir)/factory
    185 
    186 nobase_libfactory_include_HEADERS = \
    187     cf_gmp.h $(templateincl)
     185libfactory_includedir = ${includedir}/factory
    188186
    189187nodist_libfactory_include_HEADERS = cplusplus.h factory.h factoryconf.h
     
    253251                templates/ftmpl_matrix.cc
    254252
    255 templateincl =  templates/ftmpl_array.h \
    256                 templates/ftmpl_factor.h \
    257                 templates/ftmpl_list.h \
    258                 templates/ftmpl_matrix.h
    259 
    260253# header templates
    261254hdrtemplsrc =   factoryconf.template \
     
    316309
    317310cplusplus.h: cplusplus
    318         ${abs_builddir}/cplusplus > ${abs_builddir}/cplusplus.h
     311        ./cplusplus >$@
     312        cp $@ include/factory/
    319313
    320314.template.h:
    321315        ${srcdir}/bin/makeheader $< $@
     316        cp $@ include/factory/
    322317
    323318# factory/gfops.cc has the gftables path hardcoded in, so we create a
  • factory/NTLconvert.cc

    rf0168a5 ree668e  
    1414#include "cf_algorithm.h"
    1515
    16 #include "cf_gmp.h"
     16#include <factory/cf_gmp.h>
    1717
    1818#ifdef HAVE_NTL
  • factory/NTLconvert.h

    rf0168a5 ree668e  
    55#ifdef HAVE_NTL
    66
    7 // #include "cf_gmp.h"
     7// #include <factory/cf_gmp.h>
    88
    99#include "cf_defs.h"
  • factory/algext.cc

    rf0168a5 ree668e  
    1 #include "factoryconf.h"
     1#include <factory/factoryconf.h>
    22
    33#ifndef NOSTREAMIO
  • factory/canonicalform.cc

    rf0168a5 ree668e  
    1717#include "cf_binom.h"
    1818
    19 #include "cf_gmp.h"
     19#include <factory/cf_gmp.h>
    2020
    2121
  • factory/canonicalform.h

    rf0168a5 ree668e  
    2121#include "cf_defs.h"
    2222#include "variable.h"
    23 #include "templates/ftmpl_list.h"
    24 #include "templates/ftmpl_array.h"
    25 #include "templates/ftmpl_factor.h"
    26 #include "templates/ftmpl_matrix.h"
     23#include <factory/templates/ftmpl_list.h>
     24#include <factory/templates/ftmpl_array.h>
     25#include <factory/templates/ftmpl_factor.h>
     26#include <factory/templates/ftmpl_matrix.h>
    2727
    2828/*BEGINPUBLIC*/
  • factory/cf_factor.cc

    rf0168a5 ree668e  
    3939#endif
    4040
    41 #include "cf_gmp.h"
     41#include <factory/cf_gmp.h>
    4242
    4343int getExp(); /* cf_char.cc */
  • factory/cf_map.h

    rf0168a5 ree668e  
    2525#include "variable.h"
    2626#include "canonicalform.h"
    27 #include "templates/ftmpl_list.h"
     27#include <factory/templates/ftmpl_list.h>
    2828
    2929/*BEGINPUBLIC*/
  • factory/configure.ac

    rf0168a5 ree668e  
    455455    [test x$with_Singular != xyes && test x$enable_streamio != xno])
    456456
    457 AC_CONFIG_FILES([Makefile libfac/Makefile]) #  ftest/GNUmakefile
     457AC_CONFIG_FILES([Makefile include/factory/Makefile libfac/Makefile]) #  ftest/GNUmakefile
    458458AC_OUTPUT
    459459
  • factory/fac_cantzass.cc

    rf0168a5 ree668e  
    1313#include "gmpext.h"
    1414
    15 #include "cf_gmp.h"
     15#include <factory/cf_gmp.h>
    1616
    1717static CanonicalForm randomPoly( int n, const Variable & x, const CFRandom & gen );
  • factory/ftmpl_inst.cc

    rf0168a5 ree668e  
    1414#include "config.h"
    1515
    16 #include "factoryconf.h"
     16#include <factory/factoryconf.h>
    1717
    1818#include "factory.h"
  • factory/gmpext.h

    rf0168a5 ree668e  
    66
    77// #include "config.h"
    8 // #include "cf_gmp.h"
     8// #include <factory/cf_gmp.h>
    99
    1010#include "cf_defs.h"
  • factory/int_int.cc

    rf0168a5 ree668e  
    88#include "int_int.h"
    99#include "int_rat.h"
    10 #include "cf_gmp.h"
     10#include <factory/cf_gmp.h>
    1111#include "gmpext.h"
    1212
  • factory/int_int.h

    rf0168a5 ree668e  
    2020
    2121#include "int_cf.h"
    22 // #include "cf_gmp.h"
     22// #include <factory/cf_gmp.h>
    2323#include "gmpext.h"
    2424
  • factory/int_intdiv.cc

    rf0168a5 ree668e  
    1515#include "int_int.h"
    1616#include "int_rat.h"
    17 #include "cf_gmp.h"
     17#include <factory/cf_gmp.h>
    1818#include "gmpext.h"
    1919#include "templates/ftmpl_functions.h"
  • factory/int_rat.h

    rf0168a5 ree668e  
    2222#include "int_cf.h"
    2323#include "imm.h"
    24 // #include "cf_gmp.h"
     24// #include <factory/cf_gmp.h>
    2525
    2626class InternalRational : public InternalCF
  • factory/readcf.yy

    rf0168a5 ree668e  
    55
    66#include "config.h"
    7 #include "factoryconf.h"
     7#include <factory/factoryconf.h>
    88
    99#if defined(WINNT) && ! defined(__GNUC__)
  • factory/singext.cc

    rf0168a5 ree668e  
    1414#include "cf_factory.h"
    1515
    16 #include "cf_gmp.h"
     16#include <factory/cf_gmp.h>
    1717
    1818
  • factory/sm_sparsemod.cc

    rf0168a5 ree668e  
    2828#include "sm_util.h"
    2929#include "sm_sparsemod.h"
    30 #include "templates/ftmpl_array.h"
     30#include <factory/templates/ftmpl_array.h>
    3131#include "templates/ftmpl_functions.h"
    3232
  • factory/sm_util.cc

    rf0168a5 ree668e  
    2323#include "canonicalform.h"
    2424#include "variable.h"
    25 #include "templates/ftmpl_array.h"
     25#include <factory/templates/ftmpl_array.h>
    2626
    2727//{{{ static CanonicalForm fmonome( const CanonicalForm & f  )
  • factory/sm_util.h

    rf0168a5 ree668e  
    1717#include "canonicalform.h"
    1818#include "cf_reval.h"
    19 #include "templates/ftmpl_array.h"
     19#include <factory/templates/ftmpl_array.h>
    2020
    2121typedef Array<REvaluation> REArray;
Note: See TracChangeset for help on using the changeset viewer.