[Rd] Autoconf / Windows package building problem for device package

Tadashi Kadowaki tadakado at gmail.com
Wed Jul 2 12:41:51 CEST 2008


Simon,

Now, pdf2 does not use "manually created config.h", but create own
config.h by itself.
The package also does not refer internal headers installed with R.
However, the package
needs internal headers, because original pdf device code needs them.
Therefore, It has
local copies of the headers.
Your suggestion is quite proper, and this is still bad implementation.
But, to catch up the
development of pdf device in the R core, my approach is pragmatic. I'll release
version-specific packages by using internal headers of each R
versions. If the package
checks R version strictly, this approach should be not so dangerous,
because almost
all code of pdf2 is from original pdf device code.
(I know I have to use pdf device code and headers from R 2.7.1 now)

Regards,
Tadashi Kadowaki

2008/7/2 Simon Urbanek <simon.urbanek at r-project.org>:
> Tobias,
>
> that package uses headers internal to R (a really bad thing to do). Although
> it attempts to supply them (very dangerous again since they are
> R-version-dependent) they rely on configured R sources which are not present
> on Windows. I don't have a Windows machine handy, but I dimly remember that
> you can find manually created config.h for Windows in fixed-h directory
> under gnuwin32. It's a hack (and I'm not sure if it helps), though, so I'd
> strongly suggest Tadashi to fix his package to use official API as was
> suggested a few times already.
>
> Cheers,
> Simon
>
>
> On Jul 1, 2008, at 9:57 AM, Tobias Verbeke wrote:
>
>> Dear list,
>>
>> Tadashi Kadowaki has developed a pdf device package
>> that allows to add hyperlinks and popups
>> to (currently) text, mtext and rect calls.
>>
>> The package passes R CMD check (minor warnings) and compiles
>> on MacOS X and GNU/Linux, but we do not succeed in building
>> the package for Windows.
>>
>> The current version of the package can be
>> checked out as
>>
>> svn checkout svn://svn.r-forge.r-project.org/svnroot/pdf2/trunk
>>
>> Please find the 00install.out below.
>>
>> Could anyone tell why config.h is not found?
>>
>> My practical experience with the GNU build
>> tools is very limited but I would have hoped
>> config.h.in would be processed into config.h.
>>
>> Any pointer or hint will be appreciated.
>>
>> Many thanks in advance,
>> Tobias
>>
>> P.S. 00install.out (using R 2.7.1 and a current Rtools28.exe):
>>
>>
>>
>> installing R.css in C:/DOCUME~1/tverbeke/WORKSP~2/pdf2/TRUNK~1.RCH
>>
>>
>> ---------- Making package trunk ------------
>>
>>  **********************************************
>>  WARNING: this package has a configure script
>>        It probably needs manual configuration
>>  **********************************************
>>
>>  adding build stamp to DESCRIPTION
>>  installing NAMESPACE file and metadata
>>  making DLL ...
>> gcc  -std=gnu99  -Ic:/R/R-2.7.0/include   -Iinclude -DHAVE_CONFIG_H  -O3
>> -Wall  -c devPS.c -o devPS.o
>> devPS.c:26:20: error: config.h: No such file or directory
>> In file included from devPS.c:29:
>> include/Defn.h:1022: error: expected '=', ',', ';', 'asm' or
>> '__attribute__' before 'Rf_onsigusr1'
>> include/Defn.h:1023: error: expected '=', ',', ';', 'asm' or
>> '__attribute__' before 'Rf_onsigusr2'
>> In file included from
>> c:\rtools\mingw\bin\../lib/gcc/mingw32/4.2.1-sjlj/../../../../include/wchar.h:352,
>>                from include/Defn.h:1126,
>>                from devPS.c:29:
>>
>> c:\rtools\mingw\bin\../lib/gcc/mingw32/4.2.1-sjlj/../../../../include/stdint.h:66:
>> error: conflicting types for 'intptr_t'
>> include/Defn.h:204: error: previous declaration of 'intptr_t' was here
>>
>> c:\rtools\mingw\bin\../lib/gcc/mingw32/4.2.1-sjlj/../../../../include/stdint.h:75:
>> error: conflicting types for 'uintptr_t'
>> include/Defn.h:207: error: previous declaration of 'uintptr_t' was here
>> devPS.c: In function 'pathcmp':
>> devPS.c:449: error: 'FILESEP' undeclared (first use in this function)
>> devPS.c:449: error: (Each undeclared identifier is reported only once
>> devPS.c:449: error: for each function it appears in.)
>> devPS.c: In function 'LoadEncoding':
>> devPS.c:515: error: 'FILESEP' undeclared (first use in this function)
>> devPS.c: In function 'PostScriptLoadFontMetrics':
>> devPS.c:560: error: 'FILESEP' undeclared (first use in this function)
>> devPS.c: In function 'PostScriptMetricInfo':
>> devPS.c:862: warning: implicit declaration of function 'Riconv_open'
>> devPS.c:862: warning: assignment makes pointer from integer without a cast
>> devPS.c:872: warning: implicit declaration of function 'Riconv'
>> devPS.c:874: warning: implicit declaration of function 'Riconv_close'
>> devPS.c: In function 'mbcsToSbcs':
>> devPS.c:4020: warning: assignment makes pointer from integer without a
>> cast
>> devPS.c:4029: error: 'EILSEQ' undeclared (first use in this function)
>> devPS.c: In function 'PDF_NewPage':
>> devPS.c:6406: warning: unused variable 'i'
>> devPS.c: In function 'PDF_StrSize':
>> devPS.c:7129: warning: unused variable 'face'
>> devPS.c:7128: warning: unused variable 'pd'
>> devPS.c: In function 'PDFAnnotBox':
>> devPS.c:7469: warning: passing argument 5 of 'Rf_GConvert' from
>> incompatible pointer type
>> devPS.c:7470: warning: passing argument 5 of 'Rf_GConvert' from
>> incompatible pointer type
>> make[3]: *** [devPS.o] Error 1
>> make[2]: *** [srcDynlib] Error 2
>> make[1]: *** [all] Error 2
>> make: *** [pkg-trunk] Error 2
>> *** Installation of trunk failed ***
>>
>> Removing 'C:/DOCUME~1/tverbeke/WORKSP~2/pdf2/TRUNK~1.RCH/trunk'
>>
>> ______________________________________________
>> R-devel at r-project.org mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-devel
>>
>>
>
> ______________________________________________
> R-devel at r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-devel
>



-- 
門脇 正史
tadakado at gmail.com



More information about the R-devel mailing list