Changeset 3edea1 in git


Ignore:
Timestamp:
Feb 19, 2021, 9:18:42 PM (2 years ago)
Author:
Hans Schoenemann <hannes@…>
Branches:
(u'spielwiese', '828514cf6e480e4bafc26df99217bf2a1ed1ef45')
Children:
c862f03b61a6c0dba7a6e4eb197ceb7ac0304b53
Parents:
33dd62182b65166a5cf7662ec505fa7b3f4b17a3
Message:
cygwin port: shared lib libfactory
Location:
factory
Files:
25 edited

Legend:

Unmodified
Added
Removed
  • factory/Makefile.am

    r33dd62 r3edea1  
    44
    55AM_CPPFLAGS = -I${builddir}/include -I${srcdir}/include -I${srcdir} \
     6-DFACTORY_BUILDING_DLL \
    67$(OMALLOC_INCLUDES) $(RESOURCES_INCLUDES) \
    78$(FLINT_CFLAGS) $(NTL_CPPFLAGS) $(GMP_CPPFLAGS) $(SINGULAR_CFLAGS)
     
    1213$(FLINT_LIBS) $(NTL_LIBS) $(GMP_LIBS)
    1314
    14 libfactory_la_LDFLAGS    = $(SINGULAR_LDFLAGS) -release ${PACKAGE_VERSION}
     15libfactory_la_LDFLAGS    = -no-undefined $(SINGULAR_LDFLAGS) -release ${PACKAGE_VERSION}
    1516
    1617# factory source files
  • factory/canonicalform.h

    r33dd62 r3edea1  
    7676 * @sa int_poly.h, variable.h, ffops.h, gfops.h, imm.h, int_int.h, int_rat.h
    7777**/
    78 class CanonicalForm
     78class FACTORY_PUBLIC CanonicalForm
    7979#ifdef HAVE_OMALLOC
    8080#ifndef XMEMORY_H
     
    179179    friend CF_NO_INLINE CanonicalForm operator - ( const CanonicalForm& );
    180180
    181     friend void divrem ( const CanonicalForm&, const CanonicalForm&, CanonicalForm&, CanonicalForm& );
     181    friend void FACTORY_PUBLIC divrem ( const CanonicalForm&, const CanonicalForm&, CanonicalForm&, CanonicalForm& );
    182182    friend bool divremt ( const CanonicalForm&, const CanonicalForm&, CanonicalForm&, CanonicalForm& );
    183183    friend bool tryDivremt ( const CanonicalForm&, const CanonicalForm&, CanonicalForm&, CanonicalForm&, const CanonicalForm&, bool& );
     
    233233CanonicalForm blcm ( const CanonicalForm & f, const CanonicalForm & g );
    234234
    235 CanonicalForm power ( const CanonicalForm & f, int n );
    236 
    237 CanonicalForm power ( const Variable & v, int n );
     235CanonicalForm FACTORY_PUBLIC power ( const CanonicalForm & f, int n );
     236
     237CanonicalForm FACTORY_PUBLIC power ( const Variable & v, int n );
    238238//}}}
    239239
    240240//{{{ function declarations from cf_gcd.cc
    241 CanonicalForm gcd ( const CanonicalForm&, const CanonicalForm& );
     241CanonicalForm FACTORY_PUBLIC gcd ( const CanonicalForm&, const CanonicalForm& );
    242242
    243243CanonicalForm gcd_poly ( const CanonicalForm & f, const CanonicalForm & g );
     
    259259CanonicalForm swapvar ( const CanonicalForm &, const Variable &, const Variable & );
    260260
    261 CanonicalForm replacevar ( const CanonicalForm &, const Variable &, const Variable & );
     261CanonicalForm FACTORY_PUBLIC replacevar ( const CanonicalForm &, const Variable &, const Variable & );
    262262
    263263int getNumVars( const CanonicalForm & f );
     
    369369
    370370//{{{ other function declarations
    371 void setCharacteristic( int c ); // -> Fp && Q
     371void FACTORY_PUBLIC setCharacteristic( int c ); // -> Fp && Q
    372372void setCharacteristic( int c, int n ); // -> PrimePower
    373373void setCharacteristic( int c, int n, char name ); // -> GF(q)
    374374
    375 int getCharacteristic();
     375int FACTORY_PUBLIC getCharacteristic();
    376376int getGFDegree();
    377377CanonicalForm getGFGenerator();
    378378
    379 void On( int );
    380 void Off( int );
    381 bool isOn( int );
     379void FACTORY_PUBLIC On( int );
     380void FACTORY_PUBLIC Off( int );
     381bool FACTORY_PUBLIC isOn( int );
    382382//}}}
    383383
  • factory/cfCharSets.h

    r33dd62 r3edea1  
    6565
    6666/// irreducible characteristic series
    67 ListCFList
     67ListCFList FACTORY_PUBLIC
    6868irrCharSeries (const CFList & PS);
    6969
     
    8282
    8383// the same as neworder(...) only returning a list of int 's (i.e. the levels)
    84 IntList neworderint (const CFList & PolyList);
     84IntList FACTORY_PUBLIC neworderint (const CFList & PolyList);
    8585
    8686// for library internal use only:
  • factory/cfUnivarGcd.cc

    r33dd62 r3edea1  
    77#include "cf_primes.h"
    88#include "cfGcdUtil.h"
     9#include "cfUnivarGcd.h"
    910
    1011#ifdef HAVE_NTL
  • factory/cfUnivarGcd.h

    r33dd62 r3edea1  
    3232
    3333/*BEGINPUBLIC*/
    34 CanonicalForm
     34CanonicalForm FACTORY_PUBLIC
    3535extgcd ( const CanonicalForm & f, const CanonicalForm & g, CanonicalForm & a, CanonicalForm & b );
    3636/*ENDPUBLIC*/
  • factory/cf_algorithm.h

    r33dd62 r3edea1  
    3737void psqr ( const CanonicalForm & f, const CanonicalForm & g, CanonicalForm & q, CanonicalForm & r, const Variable & x );
    3838
    39 CanonicalForm bCommonDen ( const CanonicalForm & f );
     39CanonicalForm FACTORY_PUBLIC bCommonDen ( const CanonicalForm & f );
    4040
    4141bool fdivides ( const CanonicalForm & f, const CanonicalForm & g );
     
    5151
    5252//{{{ function declarations from cf_chinese.cc
    53 void chineseRemainder ( const CanonicalForm & x1, const CanonicalForm & q1, const CanonicalForm & x2, const CanonicalForm & q2, CanonicalForm & xnew, CanonicalForm & qnew );
     53void FACTORY_PUBLIC chineseRemainder ( const CanonicalForm & x1, const CanonicalForm & q1, const CanonicalForm & x2, const CanonicalForm & q2, CanonicalForm & xnew, CanonicalForm & qnew );
    5454
    55 void chineseRemainder ( const CFArray & x, const CFArray & q, CanonicalForm & xnew, CanonicalForm & qnew );
     55void FACTORY_PUBLIC chineseRemainder ( const CFArray & x, const CFArray & q, CanonicalForm & xnew, CanonicalForm & qnew );
    5656
    57 void chineseRemainderCached ( const CanonicalForm & x1, const CanonicalForm & q1, const CanonicalForm & x2, const CanonicalForm & q2, CanonicalForm & xnew, CanonicalForm & qnew, CFArray &inv );
    58 void chineseRemainderCached(const CFArray &a, const CFArray &n, CanonicalForm &xnew, CanonicalForm &prod, CFArray &inv);
     57void FACTORY_PUBLIC chineseRemainderCached ( const CanonicalForm & x1, const CanonicalForm & q1, const CanonicalForm & x2, const CanonicalForm & q2, CanonicalForm & xnew, CanonicalForm & qnew, CFArray &inv );
     58void FACTORY_PUBLIC chineseRemainderCached(const CFArray &a, const CFArray &n, CanonicalForm &xnew, CanonicalForm &prod, CFArray &inv);
    5959
    6060
     
    6969bool isPurePoly_m(const CanonicalForm & f);
    7070
    71 CFFList factorize ( const CanonicalForm & f, bool issqrfree = false );
     71CFFList FACTORY_PUBLIC factorize ( const CanonicalForm & f, bool issqrfree = false );
    7272
    73 CFFList factorize ( const CanonicalForm & f, const Variable & alpha );
     73CFFList FACTORY_PUBLIC factorize ( const CanonicalForm & f, const Variable & alpha );
    7474
    75 CFFList sqrFree ( const CanonicalForm & f, bool sort= false );
     75CFFList FACTORY_PUBLIC sqrFree ( const CanonicalForm & f, bool sort= false );
    7676
    7777CanonicalForm homogenize( const CanonicalForm & f, const Variable & x);
     
    8888bool linearSystemSolve ( CFMatrix & M );
    8989
    90 CanonicalForm determinant ( const CFMatrix & M, int n );
     90CanonicalForm FACTORY_PUBLIC determinant ( const CFMatrix & M, int n );
    9191//}}}
    9292
     
    9494CFArray subResChain ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x );
    9595
    96 CanonicalForm resultant ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x );
     96CanonicalForm FACTORY_PUBLIC resultant ( const CanonicalForm & f, const CanonicalForm & g, const Variable & x );
    9797//}}}
    9898
  • factory/cf_hnf.h

    r33dd62 r3edea1  
    2020**/
    2121
    22 CFMatrix* cf_HNF(CFMatrix& A);
     22CFMatrix* FACTORY_PUBLIC cf_HNF(CFMatrix& A);
    2323
    2424/**
     
    4242**/
    4343
    44 CFMatrix* cf_LLL(CFMatrix& A);
     44CFMatrix* FACTORY_PUBLIC cf_LLL(CFMatrix& A);
    4545
    4646/*ENDPUBLIC*/
  • factory/cf_inline.cc

    r33dd62 r3edea1  
    7979#include "config.h"
    8080
     81#ifdef __CYGWIN__
     82#undef CF_USE_INLINE
     83#endif
    8184
    8285#include "cf_assert.h"
     
    499502 * @sa CanonicalForm::operator +=()
    500503**/
     504#ifdef CF_USE_INLINE
    501505CF_INLINE CanonicalForm
     506#else
     507CF_INLINE CanonicalForm FACTORY_PUBLIC
     508#endif
    502509operator + ( const CanonicalForm & lhs, const CanonicalForm & rhs )
    503510{
     
    508515
    509516#ifndef INCL_CF_INLINE_CC
     517CF_INLINE CanonicalForm FACTORY_PUBLIC
     518operator - ( const CanonicalForm & lhs, const CanonicalForm & rhs )
     519{
     520    CanonicalForm result( lhs );
     521    result -= rhs;
     522    return result;
     523}
     524#endif
     525
     526/**
     527 * @sa CanonicalForm::operator *=()
     528**/
     529#ifdef CF_USE_INLINE
    510530CF_INLINE CanonicalForm
    511 operator - ( const CanonicalForm & lhs, const CanonicalForm & rhs )
    512 {
    513     CanonicalForm result( lhs );
    514     result -= rhs;
    515     return result;
    516 }
    517 #endif
    518 
    519 /**
    520  * @sa CanonicalForm::operator *=()
    521 **/
    522 CF_INLINE CanonicalForm
     531#else
     532CF_INLINE CanonicalForm FACTORY_PUBLIC
     533#endif
    523534operator * ( const CanonicalForm & lhs, const CanonicalForm & rhs )
    524535{
     
    532543 * @sa CanonicalForm::operator /=()
    533544**/
    534 CF_INLINE CanonicalForm
     545CF_INLINE CanonicalForm FACTORY_PUBLIC
    535546operator / ( const CanonicalForm & lhs, const CanonicalForm & rhs )
    536547{
     
    543554 * @sa CanonicalForm::operator %=()
    544555**/
    545 CF_INLINE CanonicalForm
     556CF_INLINE CanonicalForm FACTORY_PUBLIC
    546557operator % ( const CanonicalForm & lhs, const CanonicalForm & rhs )
    547558{
  • factory/cf_iter.h

    r33dd62 r3edea1  
    4242 *       variable
    4343**/
    44 class CFIterator {
     44class FACTORY_PUBLIC CFIterator {
    4545private:
    4646    CanonicalForm data;
  • factory/cf_primes.h

    r33dd62 r3edea1  
    1010#define INCL_CF_PRIMES_H
    1111
    12 // #include "config.h"
     12#include "globaldefs.h"
    1313
    1414/*BEGINPUBLIC*/
    1515
    16 int cf_getPrime( int i );
     16int FACTORY_PUBLIC cf_getPrime( int i );
    1717
    18 int cf_getNumPrimes();
     18int FACTORY_PUBLIC cf_getNumPrimes();
    1919
    20 int cf_getSmallPrime( int i );
     20int FACTORY_PUBLIC cf_getSmallPrime( int i );
    2121
    22 int cf_getNumSmallPrimes();
     22int FACTORY_PUBLIC cf_getNumSmallPrimes();
    2323
    24 int cf_getBigPrime( int i );
     24int FACTORY_PUBLIC cf_getBigPrime( int i );
    2525
    26 int cf_getNumBigPrimes();
     26int FACTORY_PUBLIC cf_getNumBigPrimes();
    2727
    2828/*ENDPUBLIC*/
  • factory/cf_random.h

    r33dd62 r3edea1  
    9494
    9595/// random seed initializer
    96 void factoryseed( int s );
     96void FACTORY_PUBLIC factoryseed( int s );
    9797
    9898/*ENDPUBLIC*/
  • factory/cf_roots.h

    r33dd62 r3edea1  
    22#define CF_ROOTS_H
    33
    4 int* Zp_roots (const CanonicalForm f);
     4int* FACTORY_PUBLIC Zp_roots (const CanonicalForm f);
    55
    66
  • factory/cf_util.cc

    r33dd62 r3edea1  
    1515#include "globaldefs.h"
    1616#include "config.h"
     17#include "cf_util.h"
    1718
    1819
  • factory/cf_util.h

    r33dd62 r3edea1  
    1010/*BEGINPUBLIC*/
    1111int igcd (int a, int b);
    12 int ipower ( int b, int n );
     12int FACTORY_PUBLIC ipower ( int b, int n );
    1313void factoryError_intern(const char *s);
    1414EXTERN_VAR void (*factoryError)(const char *s);
  • factory/facAbsFact.h

    r33dd62 r3edea1  
    3939///         Q[t]/(t), 1 is returned), and the multiplicity of the
    4040///         absolute irreducible factor
    41 CFAFList absFactorize (const CanonicalForm& G ///<[in] poly over Q
     41CFAFList FACTORY_PUBLIC absFactorize (const CanonicalForm& G ///<[in] poly over Q
    4242                      );
    4343/*ENDPUBLIC*/
  • factory/facIrredTest.h

    r33dd62 r3edea1  
    3838/// @return probIrredTest returns 1 for irreducibility, -1 for reducibility
    3939///         or 0 if the test is not applicable
    40 int probIrredTest (const CanonicalForm& F, ///< [in] some poly over Z/p
     40int FACTORY_PUBLIC probIrredTest (const CanonicalForm& F, ///< [in] some poly over Z/p
    4141                   double error            ///< [in] 0 < error < 1
    4242                  );
  • factory/facMul.h

    r33dd62 r3edea1  
    7373///
    7474/// @sa divrem2()
    75 void divrem (
     75void FACTORY_PUBLIC divrem (
    7676           const CanonicalForm& F, ///< [in] multivariate, compressed polynomial
    7777           const CanonicalForm& G, ///< [in] multivariate, compressed polynomial
  • factory/factory.template

    r33dd62 r3edea1  
    2424
    2525#include "factory/factoryconf.h"
     26#include "factory/globaldefs.h"
    2627#include <stdint.h>
    2728#include "factory/si_log2.h"
  • factory/gf_tabutil.h

    r33dd62 r3edea1  
    1212// #include "config.h"
    1313
    14 int gf_tab_numdigits62 ( int q );
     14int FACTORY_PUBLIC gf_tab_numdigits62 ( int q );
    1515
    1616char conv62 ( int i );
     
    2020int convback62 ( char c );
    2121
    22 int convertback62 ( char * p, int n );
     22int FACTORY_PUBLIC convertback62 ( char * p, int n );
    2323
    2424#endif /* ! INCL_GF_TABUTIL_H */
  • factory/globaldefs.h

    r33dd62 r3edea1  
    1616#endif
    1717
     18#if defined(__CYGWIN__)
     19  #ifdef FACTORY_BUILDING_DLL
     20    #define FACTORY_PUBLIC __declspec(dllexport)
     21  #else
     22    #define FACTORY_PUBLIC __declspec(dllimport)
     23  #endif
     24#else
     25  #define FACTORY_PUBLIC
     26#endif
     27
    1828#endif // _SINGULAR_GLOBALDEFS_H
  • factory/include/factory/templates/ftmpl_array.h

    r33dd62 r3edea1  
    1515
    1616template <class T>
    17 class Array {
     17class FACTORY_PUBLIC Array {
    1818private:
    1919    T * data;
  • factory/include/factory/templates/ftmpl_list.h

    r33dd62 r3edea1  
    4949
    5050template <class T>
    51 class List
     51class FACTORY_PUBLIC List
    5252{
    5353private:
     
    8585
    8686template <class T>
    87 class ListIterator {
     87class FACTORY_PUBLIC ListIterator {
    8888private:
    8989    List<T> *theList;
  • factory/include/factory/templates/ftmpl_matrix.h

    r33dd62 r3edea1  
    2626
    2727template <class T>
    28 class Matrix
     28class FACTORY_PUBLIC Matrix
    2929{
    3030private:
  • factory/singext.h

    r33dd62 r3edea1  
    2121/*BEGINPUBLIC*/
    2222
    23 void gmp_numerator ( const CanonicalForm & f, mpz_ptr result );
     23void FACTORY_PUBLIC gmp_numerator ( const CanonicalForm & f, mpz_ptr result );
    2424
    25 void gmp_denominator ( const CanonicalForm & f, mpz_ptr result );
     25void FACTORY_PUBLIC gmp_denominator ( const CanonicalForm & f, mpz_ptr result );
    2626
    2727int gf_value (const CanonicalForm & f );
    2828
    29 CanonicalForm make_cf ( const mpz_ptr n );
     29CanonicalForm FACTORY_PUBLIC make_cf ( const mpz_ptr n );
    3030
    31 CanonicalForm make_cf ( const mpz_ptr n, const mpz_ptr d, bool normalize );
     31CanonicalForm FACTORY_PUBLIC make_cf ( const mpz_ptr n, const mpz_ptr d, bool normalize );
    3232
    3333CanonicalForm make_cf_from_gf ( const int z );
  • factory/variable.h

    r33dd62 r3edea1  
    3030 * factory's class for variables
    3131**/
    32 class Variable
     32class FACTORY_PUBLIC Variable
    3333{
    3434private:
     
    9090 *  @note: algebraic variables have a level < 0
    9191**/
    92 Variable rootOf( const CanonicalForm &, char name = '@' );
     92Variable FACTORY_PUBLIC rootOf( const CanonicalForm &, char name = '@' );
    9393
    9494inline int level( const Variable & v ) { return v.level(); }
     
    103103char getDefaultExtName();
    104104
    105 void prune (Variable& alpha);
     105void FACTORY_PUBLIC prune (Variable& alpha);
    106106void prune1 (const Variable& alpha);
    107107int ExtensionLevel();
Note: See TracChangeset for help on using the changeset viewer.