ASN_MODULE_SOURCES=	\
	DataInterChange.c	\
	TransferBatch.c	\
	Notification.c	\
	CallEventDetailList.c	\
	CallEventDetail.c	\
	BatchControlInfo.c	\
	AccountingInfo.c	\
	NetworkInfo.c	\
	MessageDescriptionInfoList.c	\
	MobileOriginatedCall.c	\
	MobileTerminatedCall.c	\
	SupplServiceEvent.c	\
	ServiceCentreUsage.c	\
	GprsCall.c	\
	ContentTransaction.c	\
	LocationService.c	\
	AuditControlInfo.c	\
	AccessPointNameNI.c	\
	AccessPointNameOI.c	\
	ActualDeliveryTimeStamp.c	\
	AddressStringDigits.c	\
	AdvisedCharge.c	\
	AdvisedChargeCurrency.c	\
	AdvisedChargeInformation.c	\
	AgeOfLocation.c	\
	BasicService.c	\
	BasicServiceCode.c	\
	BasicServiceCodeList.c	\
	BasicServiceUsed.c	\
	BasicServiceUsedList.c	\
	BearerServiceCode.c	\
	CalledNumber.c	\
	CalledPlace.c	\
	CalledRegion.c	\
	CallEventDetailsCount.c	\
	CallEventStartTimeStamp.c	\
	CallingNumber.c	\
	CallOriginator.c	\
	CallReference.c	\
	CallTypeGroup.c	\
	CallTypeLevel1.c	\
	CallTypeLevel2.c	\
	CallTypeLevel3.c	\
	CamelDestinationNumber.c	\
	CamelInvocationFee.c	\
	CamelServiceKey.c	\
	CamelServiceLevel.c	\
	CamelServiceUsed.c	\
	CauseForTerm.c	\
	CellId.c	\
	Charge.c	\
	ChargeableSubscriber.c	\
	ChargeableUnits.c	\
	ChargeDetail.c	\
	ChargeDetailList.c	\
	ChargeDetailTimeStamp.c	\
	ChargedItem.c	\
	ChargedPartyEquipment.c	\
	ChargedPartyHomeIdentification.c	\
	ChargedPartyHomeIdList.c	\
	ChargedPartyIdentification.c	\
	ChargedPartyIdentifier.c	\
	ChargedPartyIdList.c	\
	ChargedPartyIdType.c	\
	ChargedPartyInformation.c	\
	ChargedPartyLocation.c	\
	ChargedPartyLocationList.c	\
	ChargedPartyStatus.c	\
	ChargedUnits.c	\
	ChargeInformation.c	\
	ChargeInformationList.c	\
	ChargeRefundIndicator.c	\
	ChargeType.c	\
	ChargingId.c	\
	ChargingPoint.c	\
	ChargingTimeStamp.c	\
	ClirIndicator.c	\
	Commission.c	\
	CompletionTimeStamp.c	\
	ContentChargingPoint.c	\
	ContentProvider.c	\
	ContentProviderIdentifier.c	\
	ContentProviderIdList.c	\
	ContentProviderIdType.c	\
	ContentProviderName.c	\
	ContentServiceUsed.c	\
	ContentServiceUsedList.c	\
	ContentTransactionBasicInfo.c	\
	ContentTransactionCode.c	\
	ContentTransactionType.c	\
	CseInformation.c	\
	CurrencyConversion.c	\
	CurrencyConversionList.c	\
	CustomerIdentifier.c	\
	CustomerIdType.c	\
	DataVolume.c	\
	DataVolumeIncoming.c	\
	DataVolumeOutgoing.c	\
	DateTime.c	\
	DateTimeLong.c	\
	DefaultCallHandlingIndicator.c	\
	DepositTimeStamp.c	\
	Destination.c	\
	DestinationNetwork.c	\
	DialledDigits.c	\
	Discount.c	\
	DiscountableAmount.c	\
	DiscountApplied.c	\
	DiscountCode.c	\
	DiscountInformation.c	\
	Discounting.c	\
	DiscountingList.c	\
	DiscountRate.c	\
	DiscountValue.c	\
	DistanceChargeBandCode.c	\
	EarliestCallTimeStamp.c	\
	EquipmentId.c	\
	EquipmentIdType.c	\
	Esn.c	\
	ExchangeRate.c	\
	ExchangeRateCode.c	\
	FileAvailableTimeStamp.c	\
	FileCreationTimeStamp.c	\
	FileSequenceNumber.c	\
	FileTypeIndicator.c	\
	FixedDiscountValue.c	\
	Fnur.c	\
	GeographicalLocation.c	\
	GprsBasicCallInformation.c	\
	GprsChargeableSubscriber.c	\
	GprsDestination.c	\
	GprsLocationInformation.c	\
	GprsNetworkLocation.c	\
	GprsServiceUsed.c	\
	GsmChargeableSubscriber.c	\
	GuaranteedBitRate.c	\
	HomeBid.c	\
	HomeIdentifier.c	\
	HomeIdType.c	\
	HomeLocationDescription.c	\
	HomeLocationInformation.c	\
	HorizontalAccuracyDelivered.c	\
	HorizontalAccuracyRequested.c	\
	HSCSDIndicator.c	\
	Imei.c	\
	ImeiOrEsn.c	\
	Imsi.c	\
	IMSSignallingContext.c	\
	InternetServiceProvider.c	\
	InternetServiceProviderIdList.c	\
	IspIdentifier.c	\
	IspIdType.c	\
	ISPList.c	\
	NetworkIdType.c	\
	NetworkIdentifier.c	\
	Network.c	\
	NetworkList.c	\
	LatestCallTimeStamp.c	\
	LCSQosDelivered.c	\
	LCSQosRequested.c	\
	LCSRequestTimestamp.c	\
	LCSSPIdentification.c	\
	LCSSPIdentificationList.c	\
	LCSSPInformation.c	\
	LCSTransactionStatus.c	\
	LocalCurrency.c	\
	LocalTimeStamp.c	\
	LocationArea.c	\
	LocationDescription.c	\
	LocationIdentifier.c	\
	LocationIdType.c	\
	LocationInformation.c	\
	LocationServiceUsage.c	\
	MaximumBitRate.c	\
	Mdn.c	\
	MessageDescription.c	\
	MessageDescriptionCode.c	\
	MessageDescriptionInformation.c	\
	MessageStatus.c	\
	MessageType.c	\
	Min.c	\
	MinChargeableSubscriber.c	\
	MoBasicCallInformation.c	\
	Msisdn.c	\
	MtBasicCallInformation.c	\
	NetworkAccessIdentifier.c	\
	NetworkId.c	\
	NetworkInitPDPContext.c	\
	NetworkLocation.c	\
	NonChargedNumber.c	\
	NumberOfDecimalPlaces.c	\
	ObjectType.c	\
	OperatorSpecInfoList.c	\
	OperatorSpecInformation.c	\
	OrderPlacedTimeStamp.c	\
	OriginatingNetwork.c	\
	PacketDataProtocolAddress.c	\
	PaidIndicator.c	\
	PartialTypeIndicator.c	\
	PaymentMethod.c	\
	PdpAddress.c	\
	PDPContextStartTimestamp.c	\
	PlmnId.c	\
	PositioningMethod.c	\
	PriorityCode.c	\
	RapFileSequenceNumber.c	\
	RecEntityCode.c	\
	RecEntityCodeList.c	\
	RecEntityId.c	\
	RecEntityInfoList.c	\
	RecEntityInformation.c	\
	RecEntityType.c	\
	Recipient.c	\
	ReleaseVersionNumber.c	\
	RequestedDeliveryTimeStamp.c	\
	ResponseTime.c	\
	ResponseTimeCategory.c	\
	ScuBasicInformation.c	\
	ScuChargeType.c	\
	ScuTimeStamps.c	\
	ScuChargeableSubscriber.c	\
	Sender.c	\
	ServingBid.c	\
	ServingLocationDescription.c	\
	ServingNetwork.c	\
	ServingPartiesInformation.c	\
	SimChargeableSubscriber.c	\
	SimToolkitIndicator.c	\
	SMSDestinationNumber.c	\
	SMSOriginator.c	\
	SpecificationVersionNumber.c	\
	SsParameters.c	\
	SupplServiceActionCode.c	\
	SupplServiceCode.c	\
	SupplServiceUsed.c	\
	TapCurrency.c	\
	TapDecimalPlaces.c	\
	TaxableAmount.c	\
	Taxation.c	\
	TaxationList.c	\
	TaxCode.c	\
	TaxInformation.c	\
	TaxInformationList.c	\
	TaxRate.c	\
	TaxType.c	\
	TaxValue.c	\
	TeleServiceCode.c	\
	ThirdPartyInformation.c	\
	ThirdPartyNumber.c	\
	ThreeGcamelDestination.c	\
	TotalAdvisedCharge.c	\
	TotalAdvisedChargeRefund.c	\
	TotalAdvisedChargeValue.c	\
	TotalAdvisedChargeValueList.c	\
	TotalCallEventDuration.c	\
	TotalCharge.c	\
	TotalChargeRefund.c	\
	TotalCommission.c	\
	TotalCommissionRefund.c	\
	TotalDataVolume.c	\
	TotalDiscountRefund.c	\
	TotalDiscountValue.c	\
	TotalTaxRefund.c	\
	TotalTaxValue.c	\
	TotalTransactionDuration.c	\
	TrackedCustomerEquipment.c	\
	TrackedCustomerHomeId.c	\
	TrackedCustomerHomeIdList.c	\
	TrackedCustomerIdentification.c	\
	TrackedCustomerIdList.c	\
	TrackedCustomerInformation.c	\
	TrackedCustomerLocation.c	\
	TrackedCustomerLocList.c	\
	TrackingCustomerEquipment.c	\
	TrackingCustomerHomeId.c	\
	TrackingCustomerHomeIdList.c	\
	TrackingCustomerIdentification.c	\
	TrackingCustomerIdList.c	\
	TrackingCustomerInformation.c	\
	TrackingCustomerLocation.c	\
	TrackingCustomerLocList.c	\
	TrackingFrequency.c	\
	TrackingPeriod.c	\
	TransactionAuthCode.c	\
	TransactionDescriptionSupp.c	\
	TransactionDetailDescription.c	\
	TransactionIdentifier.c	\
	TransactionShortDescription.c	\
	TransactionStatus.c	\
	TransferCutOffTimeStamp.c	\
	TransparencyIndicator.c	\
	UserProtocolIndicator.c	\
	UtcTimeOffset.c	\
	UtcTimeOffsetCode.c	\
	UtcTimeOffsetInfo.c	\
	UtcTimeOffsetInfoList.c	\
	VerticalAccuracyDelivered.c	\
	VerticalAccuracyRequested.c	\
	AbsoluteAmount.c	\
	Bid.c	\
	Code.c	\
	AsciiString.c	\
	BCDString.c	\
	Currency.c	\
	HexString.c	\
	NumberString.c	\
	PercentageRate.c

ASN_MODULE_HEADERS=	\
	DataInterChange.h	\
	TransferBatch.h	\
	Notification.h	\
	CallEventDetailList.h	\
	CallEventDetail.h	\
	BatchControlInfo.h	\
	AccountingInfo.h	\
	NetworkInfo.h	\
	MessageDescriptionInfoList.h	\
	MobileOriginatedCall.h	\
	MobileTerminatedCall.h	\
	SupplServiceEvent.h	\
	ServiceCentreUsage.h	\
	GprsCall.h	\
	ContentTransaction.h	\
	LocationService.h	\
	AuditControlInfo.h	\
	AccessPointNameNI.h	\
	AccessPointNameOI.h	\
	ActualDeliveryTimeStamp.h	\
	AddressStringDigits.h	\
	AdvisedCharge.h	\
	AdvisedChargeCurrency.h	\
	AdvisedChargeInformation.h	\
	AgeOfLocation.h	\
	BasicService.h	\
	BasicServiceCode.h	\
	BasicServiceCodeList.h	\
	BasicServiceUsed.h	\
	BasicServiceUsedList.h	\
	BearerServiceCode.h	\
	CalledNumber.h	\
	CalledPlace.h	\
	CalledRegion.h	\
	CallEventDetailsCount.h	\
	CallEventStartTimeStamp.h	\
	CallingNumber.h	\
	CallOriginator.h	\
	CallReference.h	\
	CallTypeGroup.h	\
	CallTypeLevel1.h	\
	CallTypeLevel2.h	\
	CallTypeLevel3.h	\
	CamelDestinationNumber.h	\
	CamelInvocationFee.h	\
	CamelServiceKey.h	\
	CamelServiceLevel.h	\
	CamelServiceUsed.h	\
	CauseForTerm.h	\
	CellId.h	\
	Charge.h	\
	ChargeableSubscriber.h	\
	ChargeableUnits.h	\
	ChargeDetail.h	\
	ChargeDetailList.h	\
	ChargeDetailTimeStamp.h	\
	ChargedItem.h	\
	ChargedPartyEquipment.h	\
	ChargedPartyHomeIdentification.h	\
	ChargedPartyHomeIdList.h	\
	ChargedPartyIdentification.h	\
	ChargedPartyIdentifier.h	\
	ChargedPartyIdList.h	\
	ChargedPartyIdType.h	\
	ChargedPartyInformation.h	\
	ChargedPartyLocation.h	\
	ChargedPartyLocationList.h	\
	ChargedPartyStatus.h	\
	ChargedUnits.h	\
	ChargeInformation.h	\
	ChargeInformationList.h	\
	ChargeRefundIndicator.h	\
	ChargeType.h	\
	ChargingId.h	\
	ChargingPoint.h	\
	ChargingTimeStamp.h	\
	ClirIndicator.h	\
	Commission.h	\
	CompletionTimeStamp.h	\
	ContentChargingPoint.h	\
	ContentProvider.h	\
	ContentProviderIdentifier.h	\
	ContentProviderIdList.h	\
	ContentProviderIdType.h	\
	ContentProviderName.h	\
	ContentServiceUsed.h	\
	ContentServiceUsedList.h	\
	ContentTransactionBasicInfo.h	\
	ContentTransactionCode.h	\
	ContentTransactionType.h	\
	CseInformation.h	\
	CurrencyConversion.h	\
	CurrencyConversionList.h	\
	CustomerIdentifier.h	\
	CustomerIdType.h	\
	DataVolume.h	\
	DataVolumeIncoming.h	\
	DataVolumeOutgoing.h	\
	DateTime.h	\
	DateTimeLong.h	\
	DefaultCallHandlingIndicator.h	\
	DepositTimeStamp.h	\
	Destination.h	\
	DestinationNetwork.h	\
	DialledDigits.h	\
	Discount.h	\
	DiscountableAmount.h	\
	DiscountApplied.h	\
	DiscountCode.h	\
	DiscountInformation.h	\
	Discounting.h	\
	DiscountingList.h	\
	DiscountRate.h	\
	DiscountValue.h	\
	DistanceChargeBandCode.h	\
	EarliestCallTimeStamp.h	\
	EquipmentId.h	\
	EquipmentIdType.h	\
	Esn.h	\
	ExchangeRate.h	\
	ExchangeRateCode.h	\
	FileAvailableTimeStamp.h	\
	FileCreationTimeStamp.h	\
	FileSequenceNumber.h	\
	FileTypeIndicator.h	\
	FixedDiscountValue.h	\
	Fnur.h	\
	GeographicalLocation.h	\
	GprsBasicCallInformation.h	\
	GprsChargeableSubscriber.h	\
	GprsDestination.h	\
	GprsLocationInformation.h	\
	GprsNetworkLocation.h	\
	GprsServiceUsed.h	\
	GsmChargeableSubscriber.h	\
	GuaranteedBitRate.h	\
	HomeBid.h	\
	HomeIdentifier.h	\
	HomeIdType.h	\
	HomeLocationDescription.h	\
	HomeLocationInformation.h	\
	HorizontalAccuracyDelivered.h	\
	HorizontalAccuracyRequested.h	\
	HSCSDIndicator.h	\
	Imei.h	\
	ImeiOrEsn.h	\
	Imsi.h	\
	IMSSignallingContext.h	\
	InternetServiceProvider.h	\
	InternetServiceProviderIdList.h	\
	IspIdentifier.h	\
	IspIdType.h	\
	ISPList.h	\
	NetworkIdType.h	\
	NetworkIdentifier.h	\
	Network.h	\
	NetworkList.h	\
	LatestCallTimeStamp.h	\
	LCSQosDelivered.h	\
	LCSQosRequested.h	\
	LCSRequestTimestamp.h	\
	LCSSPIdentification.h	\
	LCSSPIdentificationList.h	\
	LCSSPInformation.h	\
	LCSTransactionStatus.h	\
	LocalCurrency.h	\
	LocalTimeStamp.h	\
	LocationArea.h	\
	LocationDescription.h	\
	LocationIdentifier.h	\
	LocationIdType.h	\
	LocationInformation.h	\
	LocationServiceUsage.h	\
	MaximumBitRate.h	\
	Mdn.h	\
	MessageDescription.h	\
	MessageDescriptionCode.h	\
	MessageDescriptionInformation.h	\
	MessageStatus.h	\
	MessageType.h	\
	Min.h	\
	MinChargeableSubscriber.h	\
	MoBasicCallInformation.h	\
	Msisdn.h	\
	MtBasicCallInformation.h	\
	NetworkAccessIdentifier.h	\
	NetworkId.h	\
	NetworkInitPDPContext.h	\
	NetworkLocation.h	\
	NonChargedNumber.h	\
	NumberOfDecimalPlaces.h	\
	ObjectType.h	\
	OperatorSpecInfoList.h	\
	OperatorSpecInformation.h	\
	OrderPlacedTimeStamp.h	\
	OriginatingNetwork.h	\
	PacketDataProtocolAddress.h	\
	PaidIndicator.h	\
	PartialTypeIndicator.h	\
	PaymentMethod.h	\
	PdpAddress.h	\
	PDPContextStartTimestamp.h	\
	PlmnId.h	\
	PositioningMethod.h	\
	PriorityCode.h	\
	RapFileSequenceNumber.h	\
	RecEntityCode.h	\
	RecEntityCodeList.h	\
	RecEntityId.h	\
	RecEntityInfoList.h	\
	RecEntityInformation.h	\
	RecEntityType.h	\
	Recipient.h	\
	ReleaseVersionNumber.h	\
	RequestedDeliveryTimeStamp.h	\
	ResponseTime.h	\
	ResponseTimeCategory.h	\
	ScuBasicInformation.h	\
	ScuChargeType.h	\
	ScuTimeStamps.h	\
	ScuChargeableSubscriber.h	\
	Sender.h	\
	ServingBid.h	\
	ServingLocationDescription.h	\
	ServingNetwork.h	\
	ServingPartiesInformation.h	\
	SimChargeableSubscriber.h	\
	SimToolkitIndicator.h	\
	SMSDestinationNumber.h	\
	SMSOriginator.h	\
	SpecificationVersionNumber.h	\
	SsParameters.h	\
	SupplServiceActionCode.h	\
	SupplServiceCode.h	\
	SupplServiceUsed.h	\
	TapCurrency.h	\
	TapDecimalPlaces.h	\
	TaxableAmount.h	\
	Taxation.h	\
	TaxationList.h	\
	TaxCode.h	\
	TaxInformation.h	\
	TaxInformationList.h	\
	TaxRate.h	\
	TaxType.h	\
	TaxValue.h	\
	TeleServiceCode.h	\
	ThirdPartyInformation.h	\
	ThirdPartyNumber.h	\
	ThreeGcamelDestination.h	\
	TotalAdvisedCharge.h	\
	TotalAdvisedChargeRefund.h	\
	TotalAdvisedChargeValue.h	\
	TotalAdvisedChargeValueList.h	\
	TotalCallEventDuration.h	\
	TotalCharge.h	\
	TotalChargeRefund.h	\
	TotalCommission.h	\
	TotalCommissionRefund.h	\
	TotalDataVolume.h	\
	TotalDiscountRefund.h	\
	TotalDiscountValue.h	\
	TotalTaxRefund.h	\
	TotalTaxValue.h	\
	TotalTransactionDuration.h	\
	TrackedCustomerEquipment.h	\
	TrackedCustomerHomeId.h	\
	TrackedCustomerHomeIdList.h	\
	TrackedCustomerIdentification.h	\
	TrackedCustomerIdList.h	\
	TrackedCustomerInformation.h	\
	TrackedCustomerLocation.h	\
	TrackedCustomerLocList.h	\
	TrackingCustomerEquipment.h	\
	TrackingCustomerHomeId.h	\
	TrackingCustomerHomeIdList.h	\
	TrackingCustomerIdentification.h	\
	TrackingCustomerIdList.h	\
	TrackingCustomerInformation.h	\
	TrackingCustomerLocation.h	\
	TrackingCustomerLocList.h	\
	TrackingFrequency.h	\
	TrackingPeriod.h	\
	TransactionAuthCode.h	\
	TransactionDescriptionSupp.h	\
	TransactionDetailDescription.h	\
	TransactionIdentifier.h	\
	TransactionShortDescription.h	\
	TransactionStatus.h	\
	TransferCutOffTimeStamp.h	\
	TransparencyIndicator.h	\
	UserProtocolIndicator.h	\
	UtcTimeOffset.h	\
	UtcTimeOffsetCode.h	\
	UtcTimeOffsetInfo.h	\
	UtcTimeOffsetInfoList.h	\
	VerticalAccuracyDelivered.h	\
	VerticalAccuracyRequested.h	\
	AbsoluteAmount.h	\
	Bid.h	\
	Code.h	\
	AsciiString.h	\
	BCDString.h	\
	Currency.h	\
	HexString.h	\
	NumberString.h	\
	PercentageRate.h

ASN_MODULE_HEADERS+=INTEGER.h
ASN_MODULE_HEADERS+=NativeEnumerated.h
ASN_MODULE_HEADERS+=IA5String.h
ASN_MODULE_SOURCES+=IA5String.c
ASN_MODULE_SOURCES+=INTEGER.c
ASN_MODULE_SOURCES+=NativeEnumerated.c
ASN_MODULE_HEADERS+=NativeInteger.h
ASN_MODULE_SOURCES+=NativeInteger.c
ASN_MODULE_HEADERS+=asn_SEQUENCE_OF.h
ASN_MODULE_SOURCES+=asn_SEQUENCE_OF.c
ASN_MODULE_HEADERS+=asn_SET_OF.h
ASN_MODULE_SOURCES+=asn_SET_OF.c
ASN_MODULE_HEADERS+=constr_CHOICE.h
ASN_MODULE_SOURCES+=constr_CHOICE.c
ASN_MODULE_HEADERS+=constr_SEQUENCE.h
ASN_MODULE_SOURCES+=constr_SEQUENCE.c
ASN_MODULE_HEADERS+=constr_SEQUENCE_OF.h
ASN_MODULE_SOURCES+=constr_SEQUENCE_OF.c
ASN_MODULE_HEADERS+=constr_SET_OF.h
ASN_MODULE_SOURCES+=constr_SET_OF.c
ASN_MODULE_HEADERS+=asn_application.h
ASN_MODULE_HEADERS+=asn_system.h
ASN_MODULE_HEADERS+=asn_codecs.h
ASN_MODULE_HEADERS+=asn_internal.h
ASN_MODULE_HEADERS+=OCTET_STRING.h
ASN_MODULE_SOURCES+=OCTET_STRING.c
ASN_MODULE_HEADERS+=BIT_STRING.h
ASN_MODULE_SOURCES+=BIT_STRING.c
ASN_MODULE_SOURCES+=asn_codecs_prim.c
ASN_MODULE_HEADERS+=asn_codecs_prim.h
ASN_MODULE_HEADERS+=ber_tlv_length.h
ASN_MODULE_SOURCES+=ber_tlv_length.c
ASN_MODULE_HEADERS+=ber_tlv_tag.h
ASN_MODULE_SOURCES+=ber_tlv_tag.c
ASN_MODULE_HEADERS+=ber_decoder.h
ASN_MODULE_SOURCES+=ber_decoder.c
ASN_MODULE_HEADERS+=der_encoder.h
ASN_MODULE_SOURCES+=der_encoder.c
ASN_MODULE_HEADERS+=constr_TYPE.h
ASN_MODULE_SOURCES+=constr_TYPE.c
ASN_MODULE_HEADERS+=constraints.h
ASN_MODULE_SOURCES+=constraints.c
ASN_MODULE_HEADERS+=xer_support.h
ASN_MODULE_SOURCES+=xer_support.c
ASN_MODULE_HEADERS+=xer_decoder.h
ASN_MODULE_SOURCES+=xer_decoder.c
ASN_MODULE_HEADERS+=xer_encoder.h
ASN_MODULE_SOURCES+=xer_encoder.c
ASN_MODULE_HEADERS+=per_support.h
ASN_MODULE_SOURCES+=per_support.c
ASN_MODULE_HEADERS+=per_decoder.h
ASN_MODULE_SOURCES+=per_decoder.c
ASN_MODULE_HEADERS+=per_encoder.h
ASN_MODULE_SOURCES+=per_encoder.c
ASN_MODULE_HEADERS+=per_opentype.h
ASN_MODULE_SOURCES+=per_opentype.c
ASN_CONVERTER_SOURCES+=converter-sample.c


lib_LTLIBRARIES=libsomething.la
libsomething_la_SOURCES=$(ASN_MODULE_SOURCES) $(ASN_MODULE_HEADERS)

# This file may be used as an input for make(3)
# Remove the lines below to convert it into a pure .am file
TARGET = tap3dump
CFLAGS += -DASN_CONVERTER_TITLE="GSM TAP3 (Transferred Account Procedure, Version 3) decoder" -DHAVE_CONFIG_H -DJUNKTEST -DPDU=DataInterChange -I.
OBJS=${ASN_MODULE_SOURCES:.c=.o} ${ASN_CONVERTER_SOURCES:.c=.o}

all: DataInterChange.c $(TARGET)

$(TARGET): ${OBJS}
	$(CC) $(CFLAGS) -o $(TARGET) ${OBJS} $(LDFLAGS) $(LIBS)

.SUFFIXES:
.SUFFIXES: .c .o

.c.o:
	$(CC) $(CFLAGS) -o $@ -c $<

clean:
	rm -f $(TARGET)
	rm -f $(OBJS)

regen: regenerate-from-asn1-source

regenerate-from-asn1-source:
	../../asn1c/asn1c -S ../../skeletons -pdu=DataInterChange ../tap3.asn1


DataInterChange.c: ../sample.makefile.regen ../tap3.asn1
	make regen-makefile
	@touch DataInterChange.c
	make

regen-makefile:
	TITLE="GSM TAP3 (Transferred Account Procedure, Version 3) decoder" \
	ASN1CMDOPTS="" \
	ASN1MODULES="../tap3.asn1" \
	ASN1PDU=DataInterChange \
	PROGNAME=tap3dump \
	../sample.makefile.regen

check: ${TARGET} check-ber check-xer check-per
	@echo ================
	@echo All tests passed
	@echo ================

check-ber:
	@if test -f sample-DataInterChange-1.[db]er ; then \
	for f in sample-DataInterChange-*.[db]er; do \
	for b in 1 17 33 980 8192; do \
	echo "Recoding $$f into XER and back ($$b)..."; \
	./${TARGET} -b $$b -iber -oxer $$f > ./.tmp.1.$$$$ || exit 2; \
	./${TARGET} -b $$b -ixer -oxer ./.tmp.1.$$$$ > ./.tmp.2.$$$$ || exit 3; \
	diff ./.tmp.1.$$$$ ./.tmp.2.$$$$ || exit 4; \
	rm -f ./.tmp.[12].$$$$; \
	echo "Test junking $$f (please wait)..."; \
	./${TARGET} -J0.0001 -n 1000 -b $$b -iber -onull $$f || exit 5; \
	./${TARGET} -J0.001 -n 1000 -b $$b -iber -onull $$f || exit 6; \
	done; done; fi

check-xer:
	@if test -f sample-DataInterChange-1.xer ; then \
	for f in sample-DataInterChange-*.xer; do \
	for b in 1 17 33 980 8192; do \
	echo "Recoding $$f into DER and back ($$b)..."; \
	./${TARGET} -b $$b -ixer -oder $$f > ./.tmp.1.$$$$ || exit 2; \
	./${TARGET} -b $$b -iber -oxer ./.tmp.1.$$$$ > ./.tmp.2.$$$$ || exit 3; \
	diff $$f ./.tmp.2.$$$$ || exit 4; \
	rm -f ./.tmp.[12].$$$$; \
	echo "Test junking $$f (please wait)..."; \
	./${TARGET} -J0.0001 -n 1000 -b $$b -ixer -onull $$f || exit 5; \
	./${TARGET} -J0.001 -n 1000 -b $$b -ixer -onull $$f || exit 6; \
	done; done; fi

check-per:
	@if test -f sample-DataInterChange-1-nopad.per ; then \
	for f in sample-DataInterChange-[1-9]-nopad.per; do \
	for b in 1 17 33 980 8192; do \
	echo "Recoding non-padded $$f into DER into XER and back ($$b)..."; \
	./${TARGET} -b $$b -per-nopad -iper -oder $$f > ./.tmp.1.$$$$ || exit 2; \
	./${TARGET} -b $$b -iber -oxer ./.tmp.1.$$$$ > ./.tmp.2.$$$$ || exit 3; \
	./${TARGET} -b $$b -ixer -oder ./.tmp.2.$$$$ > ./.tmp.3.$$$$ || exit 4; \
	diff ./.tmp.1.$$$$ ./.tmp.3.$$$$ || exit 5; \
	rm -f ./.tmp.[123].$$$$; \
	echo "Test junking $$f (please wait)..."; \
	./${TARGET} -J0.0001 -n 1000 -b $$b -per-nopad -iper -onull $$f || exit 6; \
	./${TARGET} -J0.001 -n 1000 -b $$b -per-nopad -iper -onull $$f || exit 7; \
	done; done; fi
	@if test -f sample-DataInterChange-1.per ; then \
	for f in sample-*-[1-9].per; do \
	pdu=`echo $$f | sed -E -e "s/sample-([A-Za-z-]+)-[0-9].*/\1/"`; \
	for b in 1 17 33 980 8192; do \
	echo "Recoding $$f into DER into XER and back ($$b)..."; \
	./${TARGET} -b $$b -p $$pdu -iper -oder $$f > ./.tmp.1.$$$$ || exit 3; \
	./${TARGET} -b $$b -p $$pdu -iber -oxer ./.tmp.1.$$$$ > ./.tmp.2.$$$$ || exit 4; \
	./${TARGET} -b $$b -p $$pdu -ixer -oper ./.tmp.2.$$$$ > ./.tmp.1.$$$$ || exit 5; \
	diff $$f ./.tmp.1.$$$$ || exit 6; \
	rm -f ./.tmp.[12].$$$$; \
	echo "Test junking $$f (please wait)..."; \
	./${TARGET} -J0.0001 -n 1000 -b $$b -iper -onull $$f || exit 7; \
	./${TARGET} -J0.001 -n 1000 -b $$b -iper -onull $$f || exit 8; \
	done; done; fi

distclean: clean
	rm -f $(ASN_MODULE_SOURCES)
	rm -f $(ASN_MODULE_HEADERS)
	rm -f $(ASN_CONVERTER_SOURCES) $(ASN_CONVERTER_HEADERS)
	rm -f Makefile.am.sample
