Skip to content

Commit

Permalink
OS400: adjust inclusion paths in include files to avoid "include file…
Browse files Browse the repository at this point in the history
… not found" in DB2 mode.
  • Loading branch information
Patrick Monnerat authored and Patrick Monnerat committed Aug 31, 2009
1 parent 44e2832 commit eb43871
Show file tree
Hide file tree
Showing 3 changed files with 17 additions and 7 deletions.
4 changes: 2 additions & 2 deletions packages/OS400/ccsidcurl.c
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,8 @@

#pragma enum(int)

#include <curl/curl.h>
#include <curl/mprintf.h>
#include "curl.h"
#include "mprintf.h"
#include "urldata.h"
#include "url.h"
#include "getinfo.h"
Expand Down
6 changes: 3 additions & 3 deletions packages/OS400/ccsidcurl.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@
#ifndef __CURL_CCSIDCURL_H
#define __CURL_CCSIDCURL_H

#include <curl.h>
#include <easy.h>
#include <multi.h>
#include "curl.h"
#include "easy.h"
#include "multi.h"


CURL_EXTERN char * curl_version_ccsid(unsigned int ccsid);
Expand Down
14 changes: 12 additions & 2 deletions packages/OS400/make-include.sh
Original file line number Diff line number Diff line change
Expand Up @@ -35,15 +35,25 @@ fi
copy_hfile()

{
destfile="${1}"
srcfile="${2}"
shift
shift
sed -e '1i\
#pragma enum(int)\
' -e '$a\
' "${@}" -e '$a\
#pragma enum(pop)\
' < "${2}" > "${1}"
' < "${srcfile}" > "${destfile}"
}

# Copy the header files.

DEST="${SRCPF}/`db2_name curl/curl.h`.MBR"
if action_needed "${DEST}" curl/curl.h
then copy_hfile "${DEST}" curl/curl.h -e \
's/^# *include *[<"]curl\/curlbuild.h[">]/#include "curlbuild.h"/'
fi

for HFILE in curl/*.h ${SCRIPTDIR}/ccsidcurl.h
do DEST="${SRCPF}/`db2_name \"${HFILE}\"`.MBR"
if action_needed "${DEST}" "${HFILE}"
Expand Down

0 comments on commit eb43871

Please sign in to comment.